[tor-bugs] #19459 [Applications/Tor Browser]: Write (C++) patch for window resizing parts

Tor Bug Tracker & Wiki blackhole at torproject.org
Mon Nov 7 21:56:01 UTC 2016


#19459: Write (C++) patch for window resizing parts
-------------------------------------------------+-------------------------
 Reporter:  gk                                   |          Owner:
                                                 |  arthuredelstein
     Type:  task                                 |         Status:
                                                 |  needs_review
 Priority:  Medium                               |      Milestone:
Component:  Applications/Tor Browser             |        Version:
 Severity:  Normal                               |     Resolution:
 Keywords:  tbb-torbutton-conversion,            |  Actual Points:
  TorBrowserTeam201611R                          |
Parent ID:                                       |         Points:
 Reviewer:                                       |        Sponsor:
                                                 |  SponsorU
-------------------------------------------------+-------------------------

Comment (by mcs):

 Replying to [comment:41 arthuredelstein]:
 > I have altered privacy.window.maxInnerWidth and
 privacy.window.maxInnerHeight so that they now replace the default
 1000x1000. So the user can specify that the window be smaller or larger
 than the default, but it will also stay within the availScreen and always
 be rounded.

 That looks good; thanks!

 > > The changes looked okay to Kathy and me, but when we tested on a
 Retina Mac with Sierra (OSX 10.12.1), we saw incorrect results (content
 window size was 1300 x 700 at startup).
 >
 > I can't exactly reproduce this result (maybe because I don't have
 Sierra), but I also saw an incorrect result on another version of OS X. It
 turns out that the code inside quantizeBrowserSize() was running too early
 and interfering with the startup resizing. So I added a setTimeout(..., 0)
 and the problem went away for me.

 Unfortunately, Kathy and I still see this problem. We also tested on an
 older OSX 10.11.6 system to remove Sierra and the Retina display from the
 equation, but the problem still occurred. It definitely looks like
 quantizeBrowserSize() running too early is causing the problem, because if
 I change the setTimeout() delay to 5000ms the window is sized correctly.

 One more data point: if I start fresh (after removing the TorBrowser-Data
 directory), the window is correctly sized to 1000 x 1000 pixels the first
 time I start the browser but it is wrong on subsequent runs.

 Kathy and I also tried applying your Torbutton patch to master to ensure
 that everything in our test setup was reasonably in sync (e.g., Torbutton
 and Tor Launcher) but that did not help.

--
Ticket URL: <https://trac.torproject.org/projects/tor/ticket/19459#comment:43>
Tor Bug Tracker & Wiki <https://trac.torproject.org/>
The Tor Project: anonymity online


More information about the tor-bugs mailing list