Commit Graph

975 Commits

Author SHA1 Message Date
Bobby Holley
09ce7e77ed Bug 1325734 - Simplify ElementData and eliminate the concept of consuming styles. r=emilio 2017-01-09 11:50:16 -08:00
William Chen
aed08c925f Bug 1307675 - Part 2: Record telemetry for time to first input. r=baku, data=bsmedberg 2016-11-08 11:30:57 -08:00
William Chen
8e941520c1 Bug 1307675 - Part 1: Record time from first paint to time of first input. r=baku,jwatt 2016-11-08 17:39:28 -08:00
Boris Zbarsky
93e075d001 Bug 1321803 part 1. Add an API on nsPresContext to test whether the given element would have its scrollbar styles propagated to the viewport in non-paginated mode. r=dbaron 2016-12-22 16:52:12 -08:00
Cameron McCormack
a7c175e671 Bug 1321284 - Part 5: Process document level NAC when restyling. r=bholley
MozReview-Commit-ID: GigSrTHXXte

--HG--
extra : rebase_source : 30d6f5b3b32c921ae15e69b29a9cc3d5372ad8bc
2016-12-01 16:19:50 +08:00
Bobby Holley
f8c9d884fc Bug 1317016 - Basic infrastructure for RestyleHint-driven traversal. r=emilio
MozReview-Commit-ID: 7wH5XcILVmX
2016-11-25 10:06:39 -08:00
Vincent Lequertier
15d1386c74 Bug 1312155 - Move border-width constants out of nsPresContext; r=heycam 2016-11-16 10:11:00 +01:00
Markus Stange
3994547b42 Bug 1307242 - Add a non-blank paint telemetry probe for foreground root content documents. r=bkelly, f=bsmedberg
This adds a probe called TIME_TO_NON_BLANK_PAINT_MS which reports time to
non-blank paint for root content documents whose docshell was active for the
entire time between navigation start and first non-blank paint.

MozReview-Commit-ID: 7JQdk5vHr1O

--HG--
extra : rebase_source : 66be2aab4c4a32d20fb44c88c5270c5b5cfc0b81
extra : histedit_source : 5d6bef86d4a2a2250405d24ce28c6bfd9d654f8d
2016-11-10 14:26:54 -05:00
Markus Stange
22f951e2b3 Bug 1307242 - Add infrastructure for measuring time to non-blank paint. r=bkelly
MozReview-Commit-ID: LZBQOvKZYes

--HG--
extra : rebase_source : 4bf315aab5b663fbc82b11d1961b7a6e98800d6d
extra : histedit_source : 02c003a780c0ba217d17f1c009252217010dd84e
2016-11-10 16:00:45 -05:00
Dhanesh B. Sabane
a2ef7b10a8 Bug 1308137 - Remove code around IBMBIDI_SUPPORTMODE_*. r=xidorn
MozReview-Commit-ID: 96g2DBfpfX9

--HG--
extra : rebase_source : e8a299ab8ca6af6e93cf29ab9351282076e2aa1d
2016-10-16 18:05:17 +05:30
Olli Pettay
97b9917978 Bug 1308459 - Rename RefreshDriver::PresContext() to hint about its behavior, r=tnikkel
--HG--
extra : rebase_source : 50cf1fd7f1ee052e182ae3fa84ce8648e46143cd
2016-10-12 14:27:38 +03:00
Xidorn Quan
2f49a48a09 Bug 1304302 part 10 - Replace all uses of StyleSheetHandle. r=heycam
This commit is generated by the following commands with some minor
manual adjustment:

find . \( -name '*.h' -or -name '*.cpp' \) -not -path './layout/style/StyleSheet*' -exec sed -i -b \
  -e '/^\(#include\|using\)/s/StyleSheetHandle/StyleSheet/g' \
  -e 's/\(mozilla::\)\?StyleSheetHandle::RefPtr/RefPtr<\1StyleSheet>/g' \
  -e 's/StyleSheetHandle()/nullptr/g' \
  -e 's/->AsStyleSheet()//g' \
  -e 's/StyleSheetHandle/StyleSheet*/g' {} +
sed -i -b 's/sheet->AsVoidPtr()/sheet.get()/' layout/style/Loader.cpp
sed -i -b 's/AsHandle()/this/' layout/style/StyleSheet.cpp

MozReview-Commit-ID: 7abdvlKHukd

--HG--
extra : source : e5682242db07203b5a91810fe1e243c955310588
2016-09-26 22:03:25 +10:00
Joel Maher
58f71c11c8 Backout 472858f465b0 (Bug 1290158) for perf regression.
MozReview-Commit-ID: 92eO5YtKLoj
2016-09-23 06:20:33 -04:00
Neil Rashbrook
bf6bdf8c7c Bug 1290158 Don't generate synthetic paint events for invisible documents r=mattwoodrow 2016-09-14 15:55:45 +01:00
Nicholas Nethercote
b71747b2ac Bug 1299727 - Rename NS_WARN_IF_FALSE as NS_WARNING_ASSERTION. r=erahm.
The new name makes the sense of the condition much clearer. E.g. compare:

  NS_WARN_IF_FALSE(!rv.Failed());

with:

  NS_WARNING_ASSERTION(!rv.Failed());

The new name also makes it clearer that it only has effect in debug builds,
because that's standard for assertions.

--HG--
extra : rebase_source : 886e57a9e433e0cb6ed635cc075b34b7ebf81853
2016-09-01 15:01:16 +10:00
Bobby Holley
eef73cf01e Bug 1299629 - Tweak stylo path for nsPresContext::HasCachedStyleData to avoid triggering operations too early during bootstrapping. r=emilio 2016-08-31 15:09:45 -07:00
Matteo Ferretti
c0ce371e10 Bug 1241867 - override the DPR without affecting the rendering; r=dbaron
- added overrideDPPX to nsIContentViewer
- made CSSStyleSheet and GlobalWindow using the overrideDPPX value
- added unit test with frame check

MozReview-Commit-ID: AOWpGs4vb9H

--HG--
extra : rebase_source : 45d9ae2c9b7aad835b5602e805ec7260c69c05b8
2016-08-25 13:15:19 +02:00
Emilio Cobos Álvarez
ab791a332e Bug 1292281: Devirtualize nsPresContext::HasAuthorSpecifiedRules. r=bholley
MozReview-Commit-ID: 4UF4vNaOCHz
Signed-off-by: Emilio Cobos Álvarez <ecoal95@gmail.com>
2016-08-26 04:20:01 -07:00
Emilio Cobos Álvarez
9d37bfeecc Bug 1292281: Convert the error from nsPresContext::HasAuthorSpecifiedRules in a warning in nsRuleNode. r=bholley
MozReview-Commit-ID: 7ue0MYP3Jdb
Signed-off-by: Emilio Cobos Álvarez <ecoal95@gmail.com>
2016-08-26 04:19:58 -07:00
Kartikaya Gupta
c372a788a5 Bug 1292781 - Add a test. r=tnikkel
MozReview-Commit-ID: f0UvsKMwAL
2016-08-24 09:15:42 -04:00
Nicholas Nethercote
67af4817e9 Bug 1293596 (part 2) - Rework nsIWidget bounds getters. r=mstange.
This patch makes GetBounds(), GetScreenBounds() and GetClientBounds() more
obviously infallible, like existing functions such as GetNaturalBounds() and
GetClientSize(). This results in clearer behaviour in nsCocoaWindow.mm if
Objective C exceptions occur. Along the way, the patch removes some useless
failure checks for these functions.

The patch also removes the NS_IMETHOD from GetRestoredBounds and makes that
function MOZ_MUST_USE.
2016-08-19 09:03:04 +10:00
Seth Fowler
21f89abe61 Bug 1293449 - Stop exposing SurfaceCache implementation code outside of ImageLib. r=dholbert 2016-08-15 18:19:39 -07:00
Nicholas Nethercote
e7f10a07fd Bug 1293603 (part 2) - Make Run() declarations consistent. r=erahm.
This patch makes most Run() declarations in subclasses of nsIRunnable have the
same form: |NS_IMETHOD Run() override|.

As a result of these changes, I had to add |override| to a couple of other
functions to satisfy clang's -Winconsistent-missing-override warning.

--HG--
extra : rebase_source : 815d0018b0b13329bb5698c410f500dddcc3ee12
2016-08-08 12:18:10 +10:00
Bobby Holley
7c2695a9d0 Bug 1290214 - Remove NS_ERROR for media queries and @font-face. r=emilio 2016-07-28 17:25:46 -07:00
Bobby Holley
5abb382d3d Bug 1289620 - Initialize the correct restyle manager when we attach the PresShell. r=heycam 2016-07-27 09:44:30 -07:00
Bobby Holley
1764385b32 Bug 1289620 - Separate presshell attachment and detachment in nsPresContext. r=heycam 2016-07-27 09:44:29 -07:00
Nicholas Nethercote
a913f99107 Bug 1285554 - Remove remnants of widget/qt. r=dougt,mshal.
Because bug 1282866 removed Qt support but missed a bunch of things.
* * *
Bug 1285554 - more

--HG--
extra : rebase_source : c48d2485f1fdf1c961e08d91651bbca41e3a1a53
2016-07-12 09:16:45 +10:00
Lee Salzman
16ca3223d9 Bug 1286317 - part 1 - remove Qt widget usage from gfx. r=jrmuizel 2016-07-12 20:27:57 -04:00
Andrea Marchesini
9b8df4a1d1 Bug 1270185 - create dom/url for URL API and its tests, r=ehsan
--HG--
rename : dom/base/URL.cpp => dom/url/URL.cpp
rename : dom/base/URL.h => dom/url/URL.h
rename : dom/base/URLSearchParams.cpp => dom/url/URLSearchParams.cpp
rename : dom/base/URLSearchParams.h => dom/url/URLSearchParams.h
rename : dom/base/test/file_url.jsm => dom/url/tests/file_url.jsm
rename : dom/workers/test/file_url.jsm => dom/url/tests/file_worker_url.jsm
rename : dom/workers/test/jsm_url_worker.js => dom/url/tests/jsm_url_worker.js
rename : dom/workers/test/test_bug883784.jsm => dom/url/tests/test_bug883784.jsm
rename : dom/workers/test/test_bug883784.xul => dom/url/tests/test_bug883784.xul
rename : dom/base/test/test_unknown_url_origin.html => dom/url/tests/test_unknown_url_origin.html
rename : dom/base/test/test_url.html => dom/url/tests/test_url.html
rename : dom/base/test/test_url.xul => dom/url/tests/test_url.xul
rename : dom/base/test/test_urlExceptions.html => dom/url/tests/test_urlExceptions.html
rename : dom/base/test/test_urlSearchParams.html => dom/url/tests/test_urlSearchParams.html
rename : dom/base/test/test_urlSearchParams_utf8.html => dom/url/tests/test_urlSearchParams_utf8.html
rename : dom/base/test/test_url_data.html => dom/url/tests/test_url_data.html
rename : dom/base/test/test_url_empty_port.html => dom/url/tests/test_url_empty_port.html
rename : dom/base/test/test_url_malformedHost.html => dom/url/tests/test_url_malformedHost.html
rename : dom/base/test/test_urlutils_stringify.html => dom/url/tests/test_urlutils_stringify.html
rename : dom/workers/test/test_url.html => dom/url/tests/test_worker_url.html
rename : dom/workers/test/test_url.xul => dom/url/tests/test_worker_url.xul
rename : dom/workers/test/test_urlApi.html => dom/url/tests/test_worker_urlApi.html
rename : dom/workers/test/test_urlSearchParams.html => dom/url/tests/test_worker_urlSearchParams.html
rename : dom/workers/test/test_url_exceptions.html => dom/url/tests/test_worker_url_exceptions.html
rename : dom/workers/test/urlApi_worker.js => dom/url/tests/urlApi_worker.js
rename : dom/workers/test/urlSearchParams_worker.js => dom/url/tests/urlSearchParams_worker.js
rename : dom/workers/test/url_exceptions_worker.js => dom/url/tests/url_exceptions_worker.js
rename : dom/workers/test/url_worker.js => dom/url/tests/url_worker.js
2016-06-29 07:44:18 +02:00
Jonathan Watt
b15368cfcb Bug 1279451 - Remove a lot of unnecessary includes of nsAutoPtr.h. rs=sparky 2016-06-07 21:10:18 +01:00
Kyle Huey
da5496eedf Bug 1273737: Shutdown the refresh driver when there are no more refresh drivers. r=dbaron,mchang 2016-06-06 06:51:15 -07:00
Bobby Holley
8f26af0110 Bug 1275766 - Stub out nsPresContext::HasAuthorSpecifiedRules. r=heycam 2016-05-25 22:06:38 -07:00
Jeremy Chen
685cf4c3d8 Bug 1273766 - part3: purge NS_UpdateHint inline. r=heycam
MozReview-Commit-ID: IIOT9jq8hOl

--HG--
extra : rebase_source : dfb3d874ce4419f32f13e662bd495e97ac9cac10
2016-05-23 11:26:03 +08:00
Kan-Ru Chen
d5e601ce6f Bug 1261612 - Remove TabChild::IsRootContentDocument and related methods. r=smaug
MozReview-Commit-ID: 2ms1lBfimfv
2016-05-16 10:56:07 +08:00
Neil Deakin
405358d4b3 Bug 1101975, handle access keys in content process before menus, r=masayuki 2016-05-11 08:56:42 -04:00
Nathan Froyd
efbd9a9b65 Bug 1263197 - part 2 - remove temporary variable in nsPresContext's constructor; r=dholbert
In the upcoming patch to disable logging, we're going to conditionally
turn MOZ_LOG_TEST into a constant false.  But for this instance of
MOZ_LOG_TEST in nsPresContext, turning it into a constant means that
|log| becomes unused.  Since |log| isn't used after this point, let's
move the |gfxPlatform::GetLog| call into the MOZ_LOG_TEST call, removing
the temporary variable, and making the compiler happy.
2016-05-06 09:11:17 -04:00
L. David Baron
608d04db2f Bug 1270626 - Don't leave an unhandled ErrorResult and assert when media query listeners throw exceptions. r=bzbarsky
I'm acting under the assumption that this is what's closest to what the
code does now, except without asserting in ~ErrorResult.  It also seems
closest to what event listeners will do, both based on examining code
(EventListenerManager::HandleEventSubType, which I'm hoping is the right
code to look at, calls StealNSResult, and then stores it in a member
that's ignored by most callers) and based on testing (for both click
events, and for media query listeners with this patch, the exception
gets reported to the console as an unhandled exception).  That said, I'm
not particularly well versed in the current error handling rules so I
may well be off here.

This code should presumably go away when we change this code to use
EventListeners in bug 1265622, so I don't think there's any spec that
covers this.

Without the patch, the mochitest hits the fatal assertion (after
reporting hitting the expected uncaught exception).  With the
patch the test passes.  (Tested locally.)

MozReview-Commit-ID: 5kxp6jzGzX8

--HG--
extra : transplant_source : n%B4%AE%99D%FB%B9NM%C0%A2%F0%D4%B7%8C%E7%DE4E%60
2016-05-05 21:33:47 -07:00
Kyle Huey
941ab1f522 Bug 1268313: Part 7 - Move NS_NewRunnableMethod and friends to mozilla::NewRunnableMethod. r=froydnj 2016-05-05 01:45:00 -07:00
Carsten "Tomcat" Book
ba3fe0975c Backed out changeset 85ce8cb0639a (bug 1268313)
--HG--
extra : rebase_source : 56d1cf41a2dc4959b67f834e07192a5c772176a8
2016-04-29 14:21:16 +02:00
Kyle Huey
48a594a09e Bug 1268313: Part 7 - Move NS_NewRunnableMethod and friends to mozilla::NewRunnableMethod. r=froydnj 2016-04-28 14:08:25 -07:00
Kyle Huey
c73656947b Bug 1265927: Move nsRunnable to mozilla::Runnable, CancelableRunnable to mozilla::CancelableRunnable. r=froydnj 2016-04-25 17:23:21 -07:00
Mike Conley
1cff2809c8 Bug 1264409 - Make last transaction ID available via nsIDOMWindowUtils, and pass transaction ID through MozAfterPaint. r=mattwoodrow,mrbkap
MozReview-Commit-ID: 7wCYif8F6ws

--HG--
extra : rebase_source : 5a87a558dbb7955c04842b6f8b71adb15ecd3370
2016-04-13 16:59:15 -04:00
Jonathan Kew
0d6a32ee9b Bug 1249279 - Let subdocuments' presContexts inherit the DPI setting of their parent, instead of retrieving it from their widget, to avoid using stale values from a currently-hidden widget on a screen with a different DPI. r=bz 2016-04-07 10:01:30 +01:00
Bobby Holley
479711a580 Bug 1261552 - Introduce StaticPresData and hoist some shared functionality into it. r=heycam
The complexity around the font pref cache stuff is really annoying. If we
think it's unnecessary, we could remove it in a followup.
2016-04-04 23:14:27 -07:00
Nicholas Nethercote
d376f9f82e Bug 1260871 - Remove do_GetAtom() and rename NS_NewAtom() as NS_Atomize(). r=erahm.
do_GetAtom() is currently just a synonym for NS_NewAtom().

--HG--
extra : rebase_source : f4409784f931616cbc300591e6b843d30805c273
2016-03-29 10:09:43 +11:00
Timothy Nikkel
8d09d0af0a Bug 1259817. Always clear RefPtr to refresh driver in nsPresContext::Destroy. r=mats
nsPresContext::Destroy gets called from the desctructor and the cycle collector unlink phase. In the latter the prescontext may live for a while yet.
2016-03-26 00:35:15 -05:00
Brendan Dahl
3c24d63475 Bug 1256084 - Don't force reflow on size mode change. r=heycam 2016-03-23 17:56:00 -04:00
L. David Baron
fef3d844c0 Bug 1256745 - Cancel the DidPaint timer in SetShell(nullptr). r=mattwoodrow
MozReview-Commit-ID: KwtJD4AywX1
2016-03-16 13:47:41 -07:00
Jamie Nicol
4443e3c227 Bug 1247098 - Mark nsIPresShell::GetResolution and nsPresContext::IsRootContentDocument as const. r=tnikkel
MozReview-Commit-ID: 5IXm4EUy7IN

--HG--
extra : rebase_source : 7028a908adcb36828a58bb3ad7403559cfad9eb2
2016-02-24 14:57:43 +00:00
Brendan Dahl
1e077c8a5f Bug 1104916 - Implement CSS media query display-mode. r=cam 2016-02-23 17:10:00 +01:00