Skip to content
This repository has been archived by the owner. It is now read-only.

move the nav controls to left in full screen mode - in macOS Fix #7872 #8514

Merged
merged 1 commit into from May 3, 2017

Conversation

@kumarrishav
Copy link
Contributor

kumarrishav commented Apr 26, 2017

Test plan

  1. Launch Brave on macOS
  2. Click the green button in the top left to trigger full screen mode
  3. Notice the back/forward arrows move after the traffic lights disappear
  4. Move mouse into top left corner, hit green button to un-trigger full screen mode
  5. Notice traffic lights appear again and back/forward arrows pop to the right again

Description

  • Submitted a ticket for my issue if one did not already exist.
  • Used Github auto-closing keywords in the commit message.
  • Added/updated tests for this change (for new code or code which already has tests).
  • Ran git rebase -i to squash commits (if needed).

Resolves #7872

Test Plan:
screen shot 2017-04-27 at 12 12 15 am

@bsclifton bsclifton self-requested a review Apr 26, 2017
@bsclifton bsclifton added this to the 0.15.1 milestone Apr 26, 2017
Copy link

cndouglas left a comment

Unfortunately, this causes the back/forward buttons to be underneath the window controls in normal (non-fullscreen) mode.
image

@luixxiul
Copy link
Contributor

luixxiul commented Apr 28, 2017

Please look for something like :not(.fullscreen).

@kumarrishav
Copy link
Contributor Author

kumarrishav commented Apr 28, 2017

@luixxiul How should i check, if screen is in full screen mode or not?
Update : i found it :)

@NejcZdovc
Copy link
Member

NejcZdovc commented Apr 28, 2017

@kumarrishav so instead of modifying less file, you need to modify some js file. More specifically app/renderer/components/navigation/navigator.js. Here you need to check if window is maximized and if so you need to adjust margin-left for div with class backforward. Here you can see our state file. Checkout isMaximized in ui section.

@kumarrishav kumarrishav force-pushed the kumarrishav:moveNavLeft branch from a02c19d to 008758f Apr 28, 2017
@kumarrishav
Copy link
Contributor Author

kumarrishav commented Apr 28, 2017

@Liunkae review?
screen shot 2017-04-28 at 4 48 42 pm
screen shot 2017-04-28 at 4 48 51 pm

@@ -225,7 +225,7 @@ class Navigator extends ImmutableComponent {
onDragOver={this.onDragOver}
onDrop={this.onDrop}
>
<div className='backforward'>
<div className={'backforward' + (isFullScreen() ? ' fullscreen' : '')}>

This comment has been minimized.

Copy link
@NejcZdovc

NejcZdovc Apr 28, 2017

Member

Please use cx syntax for class name, you can see example bellow. Thank you

This comment has been minimized.

Copy link
@kumarrishav

kumarrishav Apr 28, 2017

Author Contributor

fixed. I wasn't aware of this utility func. @NejcZdovc Thanks .

@kumarrishav kumarrishav force-pushed the kumarrishav:moveNavLeft branch from 008758f to 7a06897 Apr 28, 2017
Copy link

cndouglas left a comment

Great job! Works for me. It even animates when you toggle fullscreen.

Copy link
Member

bsclifton left a comment

Very nice- works great 😄 Well done

@bsclifton bsclifton merged commit 42c9d1d into brave:master May 3, 2017
0 of 2 checks passed
0 of 2 checks passed
continuous-integration/appveyor/pr AppVeyor build failed
Details
continuous-integration/travis-ci/pr The Travis CI build failed
Details
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

5 participants
You can’t perform that action at this time.