Граф коммитов

83 Коммитов

Автор SHA1 Сообщение Дата
Emilio Cobos Álvarez 810916db16 Bug 1554433 - Move system colors to values::specified::color. r=xidorn
This should be an idempotent patch. The way to come up with this patch has been:

 * Run the first script attached to the bug and pipe it to xclip, then paste it
   in color.rs
 * Add the relevant #[derive] annotations and remove the color.mako.rs
   definition.
 * Reorder the values to match the ColorID definition, on which some widget
   prefs and caching stuff relies on.
 * Manually port some documentation from nsLookAndFeel.h
 * Run `rg 'eColorID_' | cut -d : -f 1 | sort | uniq >files`
 * Run the second script attached to the bug.
 * Manually fix usage of `LAST_COLOR` (adding the `End` variant), and adding
   casts to integer as needed.
 * Add an static assert so that people remember to update the prefs, rather than
   a comment on the definition :)

Differential Revision: https://phabricator.services.mozilla.com/D32610

--HG--
extra : moz-landing-system : lando
2019-05-26 13:10:00 +00:00
Martin Stransky ba6373e9aa Bug 1531338 - [Linux/Gtk] Get and use Gtk theme text color for active/pressed button, r=dao,emilio
- Follow Gtk and get theme button text color directly from "button" CSS node instead of "button label"
- Provide new -moz-gtk-buttonactivetext color for active/pressed button text color
- Replace ButtonText color with -moz-gtk-buttonactivetext when it's appropriate

Differential Revision: https://phabricator.services.mozilla.com/D30566

--HG--
extra : moz-landing-system : lando
2019-05-24 08:51:48 +00:00
Emilio Cobos Álvarez 323b5be77a Bug 1526294 - Should not need a pres context to get a system font. r=jfkthame
The only caller wants CSS pixels, no need to go back and forth.

This is the last dependency on the pres context, I think, from the style system
font code.

Differential Revision: https://phabricator.services.mozilla.com/D19147
2019-02-15 01:35:13 +01:00
Cosmin Sabou 7ccc9d8b0b Merge mozilla-inbound to mozilla-central. a=merge 2019-01-19 11:57:49 +02:00
Martin Stransky 8ddc948f81 Bug 1433667 - Honour system titlebar button left/right placement, r=dao
Differential Revision: https://phabricator.services.mozilla.com/D16466

--HG--
extra : moz-landing-system : lando
2019-01-18 13:52:29 +00:00
Martin Stransky 53be695239 Bug 1490344 - [Linux/Gtk] Enable hidden system titlebar by default on Gnome, r=dao
This patch implements -moz-gtk-csd-hide-titlebar-by-default media query
to check if the system titlebar should be disabled by default on Linux systems
(it's already disabled on Window/Mac).

It also removes explicit definition of browser.tabs.drawInTitlebar preference on Linux.
When browser.tabs.drawInTitlebar is missing the -moz-gtk-csd-hide-titlebar-by-default
is used to obtain the titlebar state. When browser.tabs.drawInTitlebar is set
in about:config or by Customize menu, the user peference is used instead of the default.

It also fixes a -moz-gtk-csd-available media query,
it was always true regardless the actual system setting.

Differential Revision: https://phabricator.services.mozilla.com/D16036

--HG--
extra : moz-landing-system : lando
2019-01-17 12:44:49 +00:00
Andreea Pavel d0b4b569af Backed out changeset aa442da7cfd8 (bug 1490344) for failing bc at browser/components/customizableui/test/browser_970511_undo_restore_default.js on a CLOSED TREE 2019-01-16 13:33:24 +02:00
Martin Stransky 0e01fab619 Bug 1490344 - [Linux/Gtk] Enable hidden system titlebar by default on Gnome, r=dao
This patch implements -moz-gtk-csd-hide-titlebar-by-default media query
to check if the system titlebar should be disabled by default on Linux systems
(it's already disabled on Window/Mac).

It also removes explicit definition of browser.tabs.drawInTitlebar preference on Linux.
When browser.tabs.drawInTitlebar is missing the -moz-gtk-csd-hide-titlebar-by-default
is used to obtain the titlebar state. When browser.tabs.drawInTitlebar is set
in about:config or by Customize menu, the user peference is used instead of the default.

It also fixes a -moz-gtk-csd-available media query,
it was always true regardless the actual system setting.

Differential Revision: https://phabricator.services.mozilla.com/D16036

--HG--
extra : moz-landing-system : lando
2019-01-15 14:47:03 +00:00
Ehsan Akhgari e5e885ae31 Bug 1521000 - Part 2: Adjust our clang-format rules to include spaces after the hash for nested preprocessor directives r=sylvestre
# ignore-this-changeset

--HG--
extra : amend_source : 7221c8d15a765df71171099468e7c7faa648f37c
extra : histedit_source : a0cce6015636202bff09e35a13f72e03257a7695
2019-01-18 10:16:18 +01:00
Sylvestre Ledru 265e672179 Bug 1511181 - Reformat everything to the Google coding style r=ehsan a=clang-format
# ignore-this-changeset

--HG--
extra : amend_source : 4d301d3b0b8711c4692392aa76088ba7fd7d1022
2018-11-30 11:46:48 +01:00
Makoto Kato 90f9f1ea2a Bug 1500876 - Remove PContent::GetSystemColors sync IPC. r=snorp,mccr8
Content process of Android uses sync IPC when initializing LookAndFeel. But
current e10s has LookAndFeel cache for start up of content process.
So we should use it, then remove sync IPC for start up performance

Differential Revision: https://phabricator.services.mozilla.com/D9750

--HG--
extra : moz-landing-system : lando
2018-10-29 01:35:47 +00:00
Martin Stransky 89822d9f40 Bug 1493145 - [CSD] Enable round corners by default by -moz-gtk-csd-transparent-background media query, r=dao
Replace mozilla.widget.use-argb-visuals pref by -moz-gtk-csd-transparent-background media query at browser.css
to draw transparent background. The media query is set by toolkit code and enabled when compatible
window manager is detected.

Differential Revision: https://phabricator.services.mozilla.com/D6658

--HG--
extra : moz-landing-system : lando
2018-09-25 11:53:04 +00:00
Hiroyuki Ikezoe 5f958f80c7 Bug 1486971 - Test for dynamically change of the prefers-reduced-motion setting on MacOSX. r=froydnj,mstange
The framework to simulate the setting change works as following;

 - nsIDOMWindowUtils.setPrefersReducedMotion() calls an IPC function which ends
   up calling nsChildView::SetPrefersReducedMotion() in the parent process

 - nsChildView::SetPrefersReducedMotion() sets the given value into
   nsLookAndFeel::mPrefersReducedMotionCached just like we set the value queried
   via NSWorkspace.accessibilityDisplayShouldReduceMotion in the parent process
   and send a notification which is the same notification MacOSX sends when the
   system setting changed

 - Normally the cached value is cleared before quering new values since the
   cache value is stale, but in this case the value is up-to-date one, so
   nsChildView::SetPrefersReducedMotion() tells that we don't need to clear the
   cache, and nsIDOMWindowUtils.resetPrefersReducedMotion() resets that state
   of 'we don't need to clear the cache'

There are two test cases with the framework in this commit, one is just setting
the value and checking the value queried by window.matchMedia.  The other one is
receiving 'change' event and checking the value of the event target.

Note that to make this test works the patch for bug 1478212 is necessary since
the test runs in an iframe.

Depends on D5003

Differential Revision: https://phabricator.services.mozilla.com/D5004

--HG--
extra : moz-landing-system : lando
2018-09-15 01:00:07 +00:00
Hiroyuki Ikezoe ef03e2a299 Bug 1035774 - Add media feature keys for hover and pointer. r=heycam,emilio
Summary:
https://drafts.csswg.org/mediaqueries-4/#hover
https://drafts.csswg.org/mediaqueries-4/#pointer

In this patch series, we don't introduce any-hover and any-pointer media
features yet, but functionalities for them on each platform backends will be
introduced in this patch series, so eIntID_AllPointerCapabilities and relevant
stuff is added in this patch for the convenience that each platform backends
can be reviewed at once.

Differential Revision: https://phabricator.services.mozilla.com/D3296
2018-08-14 17:13:04 +09:00
Tim Nguyen f0ee1746ef Bug 1472276 - Make -moz-cellhighlight distinct from Highlight and -moz-field r=karlt
Since focused+selected tree cells will no longer get an outline, we will start using a different background for the unfocused state.
That background needs to be distinct from Highlight, used on selected and focused items
and also distinct from -moz-appearance: listbox, which is used as the box background.

MozReview-Commit-ID: 7hcnueYlOXR

--HG--
extra : rebase_source : 42bb15e86252d72a3f58831079162d0f4723afc9
2018-06-29 19:23:03 +01:00
Hiroyuki Ikezoe ea2e577fa3 Bug 1365045 - Introduce keywords for prefers-reduced-motion. r=heycam
https://drafts.csswg.org/mediaqueries-5/#prefers-reduced-motion

MozReview-Commit-ID: RQUo1DBR0W
2018-07-24 16:50:47 +09:00
Stephen A Pohl 1f2e716a79 Bug 1466335: Automatically switch to the appropriate Firefox theme based on the macOS dark mode system preference. r=dao,mstange 2018-06-27 13:59:21 -04:00
Markus Stange aea1e0fbbf Bug 1417709 - Add system colors called "-moz-mac-vibrant-titlebar-light/dark" for use with -moz-font-smoothing-background-color. r=emilio
MozReview-Commit-ID: 9FbRlPvrLMX

--HG--
extra : rebase_source : 84330fd5824468e4617649828d7902fc8f001f48
2017-11-16 11:50:09 -05:00
Margareta Eliza Balazs 2cb7aeff33 Backed out 5 changesets (bug 1417709) for failing X in devtools/shared/tests/unit/test_css-properties-db.js r=backout on a CLOSED TREE
Backed out changeset 5670c9582add (bug 1417709)
Backed out changeset 50f0febe43a0 (bug 1417709)
Backed out changeset 29e6c0d82193 (bug 1417709)
Backed out changeset e3a6c5b74595 (bug 1417709)
Backed out changeset a0fe569c86c0 (bug 1417709)
2017-11-23 01:17:07 +02:00
Markus Stange 47f0dbb9c5 Bug 1417709 - Add system colors called "-moz-mac-vibrant-titlebar-light/dark" for use with -moz-font-smoothing-background-color. r=emilio
MozReview-Commit-ID: 9FbRlPvrLMX

--HG--
extra : rebase_source : 95ed15a409d00df268478b786a50b925303512c0
2017-11-16 11:50:09 -05:00
Martin Stransky 8ac700b770 Bug 1409493 - Add CSD entries to LookAndFeel, r=jhorak
MozReview-Commit-ID: Fc9sGpRrT1w

--HG--
extra : rebase_source : 4f926780cd680f9a03adc691083fc109d9fa6c81
2017-10-17 21:12:21 +02:00
Emilio Cobos Álvarez 63db5c2845 Bug 1408838: Remove -moz-physical-home-button system metric. r=xidorn
MozReview-Commit-ID: A7nZdj6GQtM

--HG--
extra : rebase_source : b721a9e21e935fdb08bb0b0342d447d89509986b
2017-10-16 08:57:59 +02:00
Emilio Cobos Álvarez e808575ca4 Bug 1406631: Remove the color-picker-available system metric. r=xidorn
All our widgets support it with a constant true.

MozReview-Commit-ID: JMEItUsxYWq

--HG--
extra : rebase_source : e7e0a3f83001813239338bc5b3895252e1fb3ea6
2017-10-07 14:06:44 +02:00
Sebastian Hengst b29f365446 Backed out changeset f70d6fcdb760 (bug 1406631) for failing color related reftests like layout/reftests/writing-mode/ua-style-sheet-input-color-1.html on Android. r=backout 2017-10-07 20:08:12 +02:00
Emilio Cobos Álvarez b7befbe6b5 Bug 1406631: Remove the color-picker-available system metric. r=xidorn
All our widgets support it with a constant true.

MozReview-Commit-ID: JMEItUsxYWq

--HG--
extra : rebase_source : a2661dce1ac191fdf098e631cd7878f0215643d5
2017-10-07 14:06:44 +02:00
Markus Stange 0704012f36 Bug 1387594 - Add system colors for use in conjunction with -moz-font-smoothing-background-color and vibrant -moz-appearances. r=dbaron
MozReview-Commit-ID: IxXZwONxy41
2017-09-14 23:09:48 +02:00
Manish Goregaokar b74c4d0f69 Bug 1386915 - Add nsLookAndFeel::NativeInit() virtual call for initializing native-side state; r=jfkthame
MozReview-Commit-ID: 8XKSC1AOI0N
2017-08-06 15:41:08 -07:00
Dão Gottwald 4b7389da4e Bug 1379938 - Rename the -moz-windows-accent-color-applies media query and make -moz-win-accentcolor available without it. r=jimm
MozReview-Commit-ID: 9zMr9JwkloF

--HG--
extra : rebase_source : 25e9cfa11dc0c3ff09e4e3aac18a53535cbcc27b
2017-07-19 16:38:49 +02:00
Dão Gottwald 8f5c440b72 Backed out changeset 5a5d8de65b70 (bug 1379938) on CLOSED TREE 2017-07-13 23:16:12 +02:00
Dão Gottwald 0f2337c0c7 Bug 1379938 - Rename the -moz-windows-accent-color-applies media query and make -moz-win-accentcolor available without it. r=jimm
MozReview-Commit-ID: BkDrm6KtiP3

--HG--
extra : rebase_source : 1c0deb5b77e1ce83a8f157c100606c563d61577c
2017-07-13 11:08:27 +02:00
Jonathan Watt 0f6107d4a9 Bug 1344910, part 2 - Add a '-moz-win-accentcolortext' color keyword to color text that will be drawn over an accent color background. r=jimm
on a CLOSED TREE, because it failed to autoland before bug 1344917 landed.

MozReview-Commit-ID: 9l2NsQlewIJ
2017-06-29 18:57:46 -07:00
Jonathan Watt 33a8a677ca Bug 1344910, part 1 - Add a '-moz-win-accentcolor' color keyword to expose the Win10 accent color. r=jimm
on a CLOSED TREE, because it failed to autoland before bug 1344917 landed.

MozReview-Commit-ID: 9jMMVnnSF5h
2017-06-29 18:57:01 -07:00
Jonathan Watt c9118ba223 Bug 1344917, part 1 - Add a '-moz-windows-accent-color-applies' media query. r=heycam
The '-moz-windows-accent-color-applies' media query matches when the Windows 10
accent color should be used as the background of the title bar.

MozReview-Commit-ID: GM7nZij6MhQ

--HG--
extra : rebase_source : ee8089ef876d0887e2c0d063015145d17eefa612
2017-06-08 14:49:21 +01:00
Chung-Sheng Fu 666911d06a Bug 1330876 - Add a new variant of LookAndFeel::GetColor that uses stand-ins for native colors and accepts default value. r=heycam
MozReview-Commit-ID: 40tmdTJbLy1

--HG--
extra : rebase_source : 391be7415abf32f77ee7371901fd0c7c3875b49e
2017-06-12 13:57:17 +08:00
L. David Baron 8f0a832c01 Bug 1371157 - Cache results of Windows system font lookups. r=jimm
I haven't really tested that this fixes the performance problem observed
in a profile without the patch because the steps to use the Gecko
Profiler on local builds on Windows are rather complicated.

MozReview-Commit-ID: FmGFs2Cvquv

--HG--
extra : transplant_source : %CB%AD%1E%2A%8F%DB%0D%9E%25%08%A82%13fP%BFS%82%BF%FC
2017-06-09 08:59:12 -07:00
Masatoshi Kimura a35278e9a7 Bug 1325368 - Assume Win7 or later when testing Windows version. r=jimm
MozReview-Commit-ID: 718G0htR17H

--HG--
extra : rebase_source : e6f7a3584f03c802218a1de526345e1df1e67cf8
2017-01-29 16:42:46 +09:00
Nicholas Nethercote 0b2b65edc8 Bug 1325503 - Remove Windows {XP, Server 2003, Vista} support from widget/. r=jimm.
I did my best to remove as much stuff as possible in this patch. The starting
point was to remove all the IsVistaOrLater() and IsWin7OrLater() calls, but I
also grepped for various strings and found some other removable stuff that way.
I may have still missed some things.

Notable things done by this patch.

- It removes numerous blocklist entries.

- It removes CanComputeVirtualKeyCodeFromScanCode(), because it's always true
  now.

- It removes ShowXP{Folder,File}Picker(), even though these were available as
  fallbacks on Vista+. The "when platform is built without the longhorn SDK"
  condition in the comment above nsFilePicker::ShowXPFolderPicker() sounds like
  it won't ever happen any more.

- It removes the config.trim_on_minimize preference. This requires adding a
  bool sHaveInitializedPrefs variable; previously the lack of pref
  initialization was indicated by the tri-state sTrimOnMinimize variable having
  the value 2.

Notable things *not* done by this patch.

- ClearThemeRegion() still exists. The comment suggests that it is XP/Vista
  only, but the code suggests otherwise. jimm thinks the comment is wrong.

- The comment in WinWakeLockListener::Callback() suggests that the StartTimer()
  call is no longer needed to block the screen saver. I'm uncertain about this
  and so I think it's best left to a follow-up.

--HG--
extra : rebase_source : f46645907d237423fd6115ab1b4725b023a0dce3
2016-12-23 13:13:31 +11:00
Jonathan Kingston 8f10491335 Bug 1302157 - Remove images-in-menu and images-in-button code (& associated icons) since it's deprecated in GTK. r=bz,dholbert
MozReview-Commit-ID: IIj8PvgdaRp

--HG--
extra : rebase_source : 21eca47872a073b382c10fe84464fac8fafd6179
2016-09-29 00:22:32 +01:00
Thomas Wisniewski e2d5d5425f Bug 1302937 - Remove -moz-mac-lion-theme. r=mstange 2016-09-16 14:42:19 -04:00
Cameron McCormack 8f06979688 Bug 1289710 - Allow KTableEntry objects to be initialized with enum values of appropriate size. r=xidorn
MozReview-Commit-ID: JluYrYmy5z1

--HG--
extra : rebase_source : a79d94130c339c58f3c1055da68f118d1320ccf3
2016-07-28 15:40:09 +08:00
Kathy Brade 61c6a3b383 Bug 232227 - Do not expose system colors to CSS or canvas. r=jmuizelaar r=enndeakin tor-r=arthuredelstein
--HG--
extra : rebase_source : 54498135a11fb7d7e9f4154ad5d5bfbf87a927bd
2015-09-25 00:59:00 +02:00
Andrew Comminos bf63f14959 Bug 1187203 - Implement GtkInfoBar appearance style on GTK3. r=karlt 2015-08-21 16:38:15 -04:00
Nick Robson 49e872dc7e Bug 1075089 - Move popup menu frame offset to LookAndFeel and fix default offset for OS X. r=Enn
--HG--
extra : rebase_source : 7817fea6ea95e9dfc486f797114e1cfb778d5230
2015-08-04 16:41:00 -04:00
Carsten "Tomcat" Book 060e1dcfe0 Backed out changeset 7edc58c272f1 (bug 1075089) for causing OS X 10.6 marionette failures in test_single_finger_desktop.py testSingleFingerMouse.test_double_tap on a CLOSED TREE 2015-07-31 14:49:40 +02:00
Nick Robson 58f8aa5dac Bug 1075089 - Moved popup menu frame offset to LookAndFeel, fixed default offset for OS X. r=enn 2015-07-30 15:00:00 +02:00
Tim Nguyen 93dcf227cd Bug 1166867 - Support -moz-os-version: windows-win10. r=jimm 2015-05-21 12:16:00 +02:00
Mike Conley 409016f0e7 Bug 1096093 - Add infrastructure for LookAndFeel metric caching, and allowing the parent process to send down cache to content process. r=jimm.
--HG--
extra : rebase_source : 884abfaaa9882c7ae69c0f54a3951dfac16036d6
extra : source : 5f9c7cd773a5826d2621601e4f4ee3581d656764
2015-04-22 10:58:15 -04:00
Carsten "Tomcat" Book 9ef77a396d Backed out changeset 5f9c7cd773a5 (bug 1096093) for bustage on a CLOSED TREE 2015-04-23 17:18:52 +02:00
Mike Conley b81c35afce Bug 1096093 - Add infrastructure for LookAndFeel metric caching, and allowing the parent process to send down cache to content process. r=jimm.
--HG--
extra : rebase_source : 0b7f90741063b98d941febc12f6c882ff2414e86
2015-04-22 10:58:15 -04:00
Gijs Kruitbosch 55e3cc3889 Bug 1044595 - fix default/active button text on OS X 10.10, r=mstange,jaws
--HG--
extra : rebase_source : c558491822fc158d44a127cfd5014bd5338d05f1
2014-09-12 00:31:15 +01:00