Commit Graph

68 Commits

Author SHA1 Message Date
Gijs Kruitbosch
26770a2b16 Bug 1629832 - add tooltips to all the window control buttons, r=dao,fluent-reviewers,flod
Differential Revision: https://phabricator.services.mozilla.com/D71199
2020-04-17 12:55:05 +00:00
monikamaheshwari
edb30ffaec Bug 1578683 Turn on ESLint rule prefer-boolean-length-check for toolkit and browser r=Standard8
Differential Revision: https://phabricator.services.mozilla.com/D45629
2019-09-14 09:39:26 +00:00
Mike Hommey
96b2f630c4 Bug 1575420 - Replace MOZ_WIDGET_TOOLKIT value of "gtk3" with "gtk". r=froydnj
Differential Revision: https://phabricator.services.mozilla.com/D42765
2019-08-21 12:25:42 +00:00
Victor Porof
a3641f184a Bug 1561435 - Format browser/base/, a=automatic-formatting
# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D36041
2019-07-05 09:48:57 +02:00
Myk Melez
5ecc2c1225 Bug 1518283 - prohibit blank lines at the beginning and end of blocks (eslint padded-blocks) r=mossop,Standard8
Differential Revision: https://phabricator.services.mozilla.com/D17526
2019-01-30 17:26:25 +00:00
Martin Stransky
7537bb8b84 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
2019-01-17 12:44:49 +00:00
Andreea Pavel
72a77bbbaf 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
8df9ea2c71 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
2019-01-15 14:47:03 +00:00
Dão Gottwald
fcfc10cf13 Bug 1509323 - Make gDragSpaceObserver private. r=johannh
Differential Revision: https://phabricator.services.mozilla.com/D12662
2018-11-23 15:59:53 +00:00
Dão Gottwald
c744223e22 Bug 1506063 - Simplify gDragSpaceObserver. r=johannh
Differential Revision: https://phabricator.services.mozilla.com/D11448
2018-11-09 10:16:34 +00:00
Dão Gottwald
d5dbede2f3 Bug 1499706 - Remove external calls to TabsInTitlebar.update and make it private. r=mconley
Differential Revision: https://phabricator.services.mozilla.com/D11311
2018-11-08 18:41:04 +00:00
Mike Conley
9eb2d4a40e Bug 1356920 - Don't calculate and flush layout inside browser-tabsintitlebar.js. r=dao
Folded together the following revisions:

Bug 1356920 - Remove all toolbar layout code from browser-tabsintitlebar. r=dao

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

***

Bug 1356920 - Move TabsToolbar and toolbar-menubar into the titlebar, and put the titlebar into the navigator-toolbox. r=dao

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

***

Bug 1356920 - Put a spacer in the menubar to push titlebar items to the end, and stop the menu from stretching vertically. r=dao

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

***

Bug 1356920 - Adjust CSS rules for new XUL document structure. r=dao

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

***

Bug 1356920 - Fix placement of tracking protection icon. r=dao

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

***

Bug 1356920 - Get rid of the spacer before the window caption buttons now in the TabsToolbar. r=dao

The spacer isn't necessary, since the tabbrowser-tabs node will flex to fill the available
space anyways.

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

***

Bug 1356920 - Move movingtab attribute to navigator-toolbox to account for TabsToolbar not being a sibling of nav-bar anymore. r=dao

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

***

Bug 1356920 - Hide the window caption buttons hbox if the native titlebar is being drawn. r=dao

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

***

Bug 1356920 - Keep the macOS window caption buttons vertically centered when drag space is enabled. r=dao

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

***

Bug 1356920 - Switch window caption XUL nodes from IDs to classes so that more than one can exist per doc. r=dao

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

***

Bug 1356920 - Move titlebar items out into a preprocessed file to be included at build-time. r=dao

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

***

Bug 1356920 - Reorganize TabsToolbar contents to force most items to the bottom of it. r=dao

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

***

Bug 1356920 - Update CSS to account for new DOM structure under TabsToolbar. r=dao

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

***

Bug 1356920 - Fix titlebar button rendering when using a lwtheme without the Windows compositor. r=dao

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

***

Bug 1356920 - Put an ordinal rule on the window caption buttons to help ensure they stay at the end of the toolbar. r=dao

This is to ensure that the buttons are placed after the post-tabs titlebar placeholder.

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

***

Bug 1356920 - Stretch window caption buttons to fill vertical space on Windows 8+ when using extra drag space. r=dao

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

***

Bug 1356920 - Update onViewToolbarsPopupShowing to search for toolbars that are grandchildren of the toolbox. r?jaws

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

***

Bug 1356920 - Hide the titlebar items in the TabsToolbar if the menubar is being displayed. r=dao

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

***

Bug 1356920 - Fix selector for titlebar. r=dao

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

***

Bug 1356920 - Fix titlebar themeing on Linux. r=dao

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

***

Bug 1356920 - Remove browser-tabsintitlebar layout flushes from performance test whitelist. r?florian

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

***

Bug 1356920 - Fix bottom border of tabbar to account for new DOM structure. r=dao

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

***

Bug 1356920 - Hide the titlebar-buttonbox-container when in fullscreen mode. r=dao

Differential Revision: https://phabricator.services.mozilla.com/D7833
2018-10-25 12:03:14 -04:00
Mark Banner
462116b7f9 Bug 1486739 - Add missing dangling commas in browser/, services/, taskcluster/ and toolkit/. r=mossop
Automatic changes by ESLint, except for manual corrections for .xml files.

Differential Revision: https://phabricator.services.mozilla.com/D4439
2018-08-31 05:59:17 +00:00
Manish Kumar
e50fbbf29f Bug 1452119 - Stop removing the resolutionchange event listener in TabsInTitlebar.uninit r=dao 2018-04-06 23:08:41 +02:00
Dão Gottwald
0a8e016dc7 Bug 1450279 - Replace CAN_DRAW_IN_TITLEBAR with a run-time check. r=Gijs
MozReview-Commit-ID: Iedpcu5K74m
2018-03-30 17:36:01 +02:00
Dão Gottwald
df7f319560 Bug 1449689 - Merge updateTitlebarDisplay function into TabsInTitlebar.update. r=johannh
MozReview-Commit-ID: IV5wrqoJmjB
2018-03-28 20:47:21 +02:00
Dão Gottwald
f914c66877 Bug 1448303 - Refactor TabsInTitlebar initial update handling. r=florian
MozReview-Commit-ID: BQTe6cVyHo1
2018-03-28 20:36:21 +02:00
Csoregi Natalia
3fedeb1f16 Backed out changeset 3e32fb05601e (bug 1448303) expected to fail on browser_windowopen.js. CLOSED TREE 2018-03-28 21:34:21 +03:00
Dão Gottwald
9eb9a0c4bb Bug 1448303 - Refactor TabsInTitlebar initial update handling. r=florian
MozReview-Commit-ID: ASVRIsVIoKa
2018-03-28 20:24:26 +02:00
Dão Gottwald
36cb1e2678 Bug 1448613 - Clean up TabsInTitlebar resize event handling. r=johannh
MozReview-Commit-ID: CXsfgWOAtwO
2018-03-26 17:24:17 +02:00
Csoregi Natalia
6978d9813e Backed out changeset a1bb89af06ba (bug 1448613) - expected to fail due to Bug 1446264. CLOSED TREE 2018-03-26 18:19:14 +03:00
Dão Gottwald
1e4cc40aa1 Bug 1448613 - Clean up TabsInTitlebar resize event handling. r=johannh
MozReview-Commit-ID: 9UaG2RHst7
2018-03-25 05:54:38 +02:00
Dão Gottwald
5baa531e25 Bug 1448078 - Set the extradragspace attribute before TabsInTitlebar does its initial update. r=johannh
MozReview-Commit-ID: 4jYJ8K3EWfa
2018-03-22 18:52:29 +01:00
Emilio Cobos Álvarez
e2d430e8b4 Bug 1445737: Ensure we only update tabsInTitlebar once during browser startup. r=dao
Two fixes here:

updateAppearance really depends on the tabbrowser.xml updateVisibility(), so
make that dependency explicit and remove the event handling from tabbrowser.

After the previous patch, TabsInTitlebar.init() runs much earlier, which means
that the initialization check that bails out from update() is not taken. Turns
out that this is definitely not an edge case, and that tons of initialization
code all over gBrowser.onDOMContentLoaded call updateAppearance(true), causing
tons of extra invalidation and reflows that aren't really needed.

Ensure we only do the work once.

MozReview-Commit-ID: 2E9b12aBast
2018-03-16 17:27:05 +01:00
Emilio Cobos Álvarez
f50030254f Bug 1445737: Simplify a bit now that we unconditionally shuffle the window attributes after init(). r=dao
MozReview-Commit-ID: 78lPD2ZISWV
2018-03-16 17:26:52 +01:00
Dão Gottwald
642186c6a3 Bug 1434621 - part 1: vertically center title bar buttons on Linux. r=stransky
MozReview-Commit-ID: 4cpEAyw1a4k
2018-02-21 16:39:59 +01:00
Brian Grinstead
c6611f00c6 Bug 1424095 - Tweak frontend CSS to play nicely in XUL flexbox emulation mode;r=Gijs
There are still known issues with the browser chrome when emulating, but this changeset is
done in service of getting the UI to be close enough to start running Talos tests against
it in Bug 1425330.

MozReview-Commit-ID: B0w1aOmi4FJ
2018-01-04 10:25:30 -08:00
Dão Gottwald
310b23880b Bug 1430747 - Stop setting unused customization-lwtheme attribute and --toolbox-rect-height, --toolbox-rect-height-with-unit CSS variables. r=mikedeboer
MozReview-Commit-ID: HpdE3I7ZeDY
2018-01-16 12:38:41 +01:00
Dale Harvey
dd69440686 Bug 1411309 - Remove margin next to chrome controls and drag space. r=johannh
MozReview-Commit-ID: 91JCjkW7mNJ
2017-11-06 14:09:48 +00:00
Martin Stransky
cac30e82d4 Bug 1414216 - Disable tabsintitlebar when disabled by -moz-gtk-csd-available media feature, r=dao
MozReview-Commit-ID: G9NHhuFwUEe
2017-11-03 10:57:00 +01:00
Dão Gottwald
1827693f4a Bug 1411642 - Don't let window controls overlap the nav bar. r=johannh
MozReview-Commit-ID: HLZoEaktNau
2017-10-26 11:46:30 +02:00
Dão Gottwald
932cceaadd Bug 1405542 - Replace nav-bar top border and the tabs toolbar's negative margin with a box-shadow to avoid running into bug 477157. r=nhnt11
MozReview-Commit-ID: KXFj740EXEz
2017-10-24 12:37:43 +02:00
Attila Craciun
f26f84278e Backed out 1 changesets (bug 1405542) for failing in OS X (browser chrome test) at browser/base/content/test/performance/browser_windowopen_reflows.js on a CLOSED TREE.
Backed out changeset f4343e201285 (bug 1405542)
2017-10-23 16:26:13 +03:00
Dão Gottwald
4a3fb4409d Bug 1405542 - Replace nav-bar top border and the tabs toolbar's negative margin with a box-shadow to avoid running into bug 477157. r=nhnt11
MozReview-Commit-ID: HFelefofjYY
2017-10-19 16:50:52 +02:00
Dão Gottwald
498f5b5fa1 Bug 1399500 - Light and Dark themes should use the same toolbar borders as the default theme. r=johannh
MozReview-Commit-ID: Cs6a7AZiOrV
2017-10-06 16:41:43 +02:00
Johann Hofmann
58bd24d84b Bug 1390885 - Remove code that adjusts the titlebar to drawing lwthemes inside the titlebar. r=nhnt11
We got rid of drawing lwthemes inside the titlebar on OSX in bug 1392219 but
there was still some code that adjusted the titlebar, which we forgot
remove. Incidentally, that code was also causing a bug (even before we
removed the in-titlebar drawing) which we now don't need to worry about
anymore now.

MozReview-Commit-ID: 44HR25Uyp8B
2017-09-28 23:16:04 +02:00
Johann Hofmann
0a07fb1637 Bug 1390448 - Restore vertical margin calculation in browser-tabsintitlebar.js, add 1px to window control margin on Windows 10. r=dao
MozReview-Commit-ID: LXR2zrAZS0k
2017-08-15 14:18:22 +02:00
Johann Hofmann
3f9b1af46d Bug 1375335 - Fix window control height calculation on Windows 10. r=dao
This commit:

- Makes the window controls have exactly the same height as tabs when the
  menubar is hidden, and have the same height as the menubar when it is shown.
  This requires us to remove the menubar height before flushing layout in
  case it is shown, since we need its original height for the calculation.

- Removes the top margin between the menu bar and the window border
  that was present on Windows 10 and makes it apply on Windows 7 only.
  The border was causing miscalculations of the window control height,
  which could have been handled in browser-tabsintitlebar.js, but since
  it's not part of the Photon spec we decide to remove it entirely.

- Makes window control height calculations ignore vertical tabs toolbar
  margins. The only margin it has right now is -1px and the calculation
  code doesn't work right with negative margins.

MozReview-Commit-ID: HJXxUUJFX8x
2017-08-09 14:36:01 +01:00
Sebastian Hengst
3fd459e69e Backed out changeset 37ba4f932f57 (bug 1375335) for failing browser_windowopen_reflows.js on OS X. r=backout 2017-08-14 15:28:01 +02:00
Johann Hofmann
bccad03ca0 Bug 1375335 - Fix window control height calculation on Windows 10. r=dao
This commit:

- Makes the window controls have exactly the same height as tabs when the
  menubar is hidden, and have the same height as the menubar when it is shown.
  This requires us to remove the menubar height before flushing layout in
  case it is shown, since we need its original height for the calculation.

- Removes the top margin between the menu bar and the window border
  that was present on Windows 10 and makes it apply on Windows 7 only.
  The border was causing miscalculations of the window control height,
  which could have been handled in browser-tabsintitlebar.js, but since
  it's not part of the Photon spec we decide to remove it entirely.

- Makes window control height calculations ignore vertical tabs toolbar
  margins. The only margin it has right now is -1px and the calculation
  code doesn't work right with negative margins.

MozReview-Commit-ID: HJXxUUJFX8x
2017-08-09 14:36:01 +01:00
Wes Kocher
86e71c3f47 Backed out changeset 739d6afc27be (bug 1375335) for failures in 739d6afc27be a=backout
MozReview-Commit-ID: CgS230WMXKs
2017-08-11 12:19:01 -07:00
Johann Hofmann
877e7b6f43 Bug 1375335 - Fix window control height calculation on Windows 10. r=dao
This commit:

- Makes the window controls have exactly the same height as tabs when the
  menubar is hidden, and have the same height as the menubar when it is shown.
  This requires us to remove the menubar height before flushing layout in
  case it is shown, since we need its original height for the calculation.

- Removes the top margin between the menu bar and the window border
  that was present on Windows 10 and makes it apply on Windows 7 only.
  The border was causing miscalculations of the window control height,
  which could have been handled in browser-tabsintitlebar.js, but since
  it's not part of the Photon spec we decide to remove it entirely.

- Makes window control height calculations ignore vertical tabs toolbar
  margins. The only margin it has right now is -1px and the calculation
  code doesn't work right with negative margins.

MozReview-Commit-ID: HJXxUUJFX8x
2017-08-09 14:36:01 +01:00
Michael Kohler
f15ab23e9f Bug 1366555 - Remove MOZ_PHOTON_THEME ifdefs and non-MOZ_PHOTON_THEME code. r=dao
MozReview-Commit-ID: 8w1vfF2yRui
2017-08-08 12:09:14 +02:00
Sebastian Hengst
31742f9ca2 Backed out changeset 1538b0445eda (bug 1366555) for timing browser_locationBarCommand.js and browser_locationBarExternalLoad.js. r=backout 2017-08-05 23:15:16 +02:00
Michael Kohler
a220eeb86a Bug 1366555 - Remove MOZ_PHOTON_THEME ifdefs and non-MOZ_PHOTON_THEME code r=dao
MozReview-Commit-ID: CoHv9mKpAe
2017-08-05 20:37:40 +02:00
Florian Quèze
441e30cff4 Bug 1381853 - lazy load browser-customization.js into the browser window, r=mconley. 2017-07-23 00:17:57 +02:00
UK992
aa491a9059 Bug 1372043 - Set height on titlebar buttons only in miximized window r=dao
MozReview-Commit-ID: 5wMN83E72in
2017-07-15 21:16:56 +02:00
Oriol
f2910111c1 Bug 1372289 - Remove 1px gap above tabs in maximzed windows. r=dao
MozReview-Commit-ID: BniFC5O3v7N
2017-06-16 12:01:25 +02:00
UK992
1efd3ee410 Bug 1185482 - Remove gap between titlebar buttons and navigation toolbar r=dao
MozReview-Commit-ID: AD2opbF4Uxn
2017-06-10 18:20:53 +02:00
Sam Foster
df7a4f25f1 Bug 1334642 - Cache luminance values for each toolbar in ToolbarIconColor. r=dao,mconley
* Track window states: active, fullscreen and tabsintitlebar for each window
* Use toolbar.id and window state to store and retrieve values from cache
* Note: As each window has its own ToolbarIconColor object, the cache is not currently shared across windows
* inferFromText callers pass in a reason and associated value, which is used to update the state we track, and potentially clear out the cache
* Create new windows test directory for browser-window-specific tests like this
* Test for the ToolbarIconColor changes to avoid sync style flushes when windows activate/deactivate

MozReview-Commit-ID: JDJ3RtL4Lge
2017-04-06 10:50:09 -07:00