jerrod-lankford / google-voice-desktop-app

An electron shell wrapper around the google voice website
247 stars 38 forks source link

Menu bar, Shortcuts for zoom, Settings updates #87

Closed eFail closed 2 years ago

eFail commented 3 years ago

Changelist:

Remarks

Removal of Injected "Customize" Button Since many users have reported various scenarios in which the "Customize" button (that gets injected into Google Voice's markup on load) goes missing, we have stripped the button out entirely. It has been replaced by a new Settings item found in the main window's Menu Bar and notification area icon context menu.

image

Zoom Shortcuts / Menu Bar In this change we do some work to support the standard keyboard shortcuts for zooming in and out that people are used to in the browser. That is, the ability to press Ctrl+= or Ctrl++ to zoom in, to press Ctrl+- or Ctrl+-_ to zoom out, and to press Ctrl+0 to reset the zoom level. The key to implementing this was to add a Menu Bar to the main application window, placing inside it the standard role zoom items that come built in to Electron. Since a Menu Bar was necessary for zoom, I took it a step further and implemented menu items for all the primary functionality in the application. F11 is now supported as well, which allows you to go full screen.

image

For those that don't want a Menu Bar, there is a new option in the Settings window for turning it off. But all zoom shortcuts will continue to work even when the Menu Bar is turned off, because rather than actually remove it, we just hide it :).

image

Zoom Slider In the Settings window, there's a new Slider control hooked up to the zoom functionality of the main window. Whereas we used to modify the zoom factor to zoom in/out, we now modify the zoom level, and we allow the exact same minimum and maximum values that the browser does (which is what Electron's built in zoom menu items allow). That is, we allow a zoom range of 25% to 500% to be selected. Additionally, we take advantage of the fact that Electron remembers the last applied zoom level (the way the browser does), so we no longer need to save this value to the user's settings store. We simply query the main window for it when it's needed.

image

Accessibility In this commit, we also make a series of tweaks to help with usability/accessibility.

Help Menu Last, but not least, under the new Help item in the Menu Bar (for discovery purposes, the Menu Bar is turned on by default for everyone initially), we add a number of items that make maintaining this application easier. image

jerrod-lankford commented 3 years ago

Thanks for your contributions. A few things: