GoldenChaos-BTT Support and Feedback Thread

Yeah, you can definitely use them - in fact, you should use them, since they'll sync up with the new now playing widget.

Excited to try it out! :smile:

1 Like

Ah the "stable" situation is a bit complicated at the moment :slight_smile:
Users who download directly from my website or do a manual update check will already receive these new versions. However they are not yet pushed actively to all users because there will be some more updates next week to fix a few issues with Mojave & Chrome 69

:+1:t2:

OK, I'm about to try it out. Wish me luck, I'm going in...

1 Like

Quick one: In the "expand to Large" script, you have "showNotificationCenter" instead of "showSiri".

I also modified the "collapse to medium" script so that it shows both the collapse to small and expand buttons (just because it seemed like a sensible thing to do). Probably needs a bit of firtling with the spacings, though, to avoid accidentally hitting the emoji button. It might also look better if the buttons were < > rather than > <.

1 Like

@Andreas_Hegenberg

Which version are you referring to as β€˜stable’?

I too had the blank escape key showing up after selecting the normal escape key in GC-BTT settings, like Randy_Saeks mentioned, selecting "Icon only, no text" helps, but fixing this manually in all the sub menu's takes a while.

On another note, would it be possible to add a setting to the GC-BTT settings menu to set the time format? I'm using 24h time format instead of 12h, but setting this manually for every menu is a lot of work.

I was thinking, would a modification along these lines help to persist configuration changes across updates? I had a look at the script for "Use Dynamic Date/Time".

tell application "BetterTouchTool"
	try
		-- Update setting indicators
		update_trigger "B164B32F-273B-4C74-83A0-EFF898F00A87" json "{\"BTTTriggerConfig\" : {\"BTTTouchBarButtonColor\" : \"129, 129, 129, 255\"}}"
		update_trigger "EC410285-7600-44EE-AC06-2267106E6DB8" json "{\"BTTTriggerConfig\" : {\"BTTTouchBarButtonColor\" : \"75, 75, 75, 255\"}}"
		update_trigger "223741CF-4327-4B94-BB0D-BE24CA56E579" json "{\"BTTTriggerConfig\" : {\"BTTTouchBarButtonColor\" : \"75, 75, 75, 255\"}}"
		update_trigger "EB808B83-ABF5-4C8E-85F9-EB0A9635BDBE" json "{\"BTTTriggerConfig\" : {\"BTTTouchBarButtonColor\" : \"75, 75, 75, 255\"}}"
		
		-- Set persistent variables
		set_persistent_string_variable "dateSize" to "dynamic"
		
		-- Update display
		if (get_string_variable "showWeather") is "never" then
			set datePadding to 8
		else if (get_string_variable "showWeather") is "always" then
			set datePadding to 0
		else
                    set menuSize to get_string_variable "menuBarSize" -- avoid multiple calls to get_string_variable
			if menuSize is "small" then
				set dateFormat to get_string_variable "dateFormatSmall"
				if dateFormat is "" then -- or whatever is returned if that variable isn't set
					set dateFormat to "h:mm a"
					set_persistent_string_variable "dateFormatSmall" to dateFormat
				end if
				set datePadding to 8
			else if menuSize is "medium" then
				set dateFormat to get_string_variable "dateFormatMedium"
				if dateFormat is "" then -- or whatever is returned if that variable isn't set
					set dateFormat to "MMM d h:mm a"
					set_persistent_string_variable "dateFormatMedium" to dateFormat
				end if
				set datePadding to 0
			else
				set dateFormat to get_string_variable "dateFormatLarge"
				if dateFormat is "" then -- or whatever is returned if that variable isn't set
					set dateFormat to "E MMM d h:mm a"
					set_persistent_string_variable "dateFormatLarge" to dateFormat
				end if
				set datePadding to 0
			end if
		end if
		update_trigger "F0AC6440-624C-417A-A0DB-93BE2A22A7D1" json "{\"BTTTriggerConfig\" : {\"BTTTouchBarDateFormat\" : \"" & dateFormat & "\", \"BTTTouchBarFreeSpaceAfterButton\" : " & datePadding & "}}"
		update_trigger "1FC3AEDF-3063-43C2-8A7F-09F43EBF6337" json "{\"BTTTriggerConfig\" : {\"BTTTouchBarDateFormat\" : \"" & dateFormat & "\", \"BTTTouchBarFreeSpaceAfterButton\" : " & datePadding & "}}"
		update_trigger "FC2890FE-6258-4994-91CA-E5613B54B9D3" json "{\"BTTTriggerConfig\" : {\"BTTTouchBarDateFormat\" : \"" & dateFormat & "\", \"BTTTouchBarFreeSpaceAfterButton\" : " & datePadding & "}}"
		update_trigger "04245966-D18E-42CF-826B-A9BF242964B3" json "{\"BTTTriggerConfig\" : {\"BTTTouchBarDateFormat\" : \"" & dateFormat & "\", \"BTTTouchBarFreeSpaceAfterButton\" : " & datePadding & "}}"
		update_trigger "F4137E86-39BD-4975-8B6B-425AD35C4934" json "{\"BTTTriggerConfig\" : {\"BTTTouchBarDateFormat\" : \"" & dateFormat & "\", \"BTTTouchBarFreeSpaceAfterButton\" : " & datePadding & "}}"
		update_trigger "D87F65D6-4661-4826-B57E-80E13181392B" json "{\"BTTTriggerConfig\" : {\"BTTTouchBarDateFormat\" : \"" & dateFormat & "\", \"BTTTouchBarFreeSpaceAfterButton\" : " & datePadding & "}}"
		update_trigger "D37A722D-5DD1-4BF0-B4A7-F828B86A0951" json "{\"BTTTriggerConfig\" : {\"BTTTouchBarDateFormat\" : \"" & dateFormat & "\", \"BTTTouchBarFreeSpaceAfterButton\" : " & datePadding & "}}"
		update_trigger "A80E036B-888F-4BDE-B552-6B57619447C9" json "{\"BTTTriggerConfig\" : {\"BTTTouchBarDateFormat\" : \"" & dateFormat & "\", \"BTTTouchBarFreeSpaceAfterButton\" : " & datePadding & "}}"
	end try
end tell

What I've done is to defer setting the persistent variables for the date/time format until after the attempt to get them. That way, they should persist across updates. All we then need is a small, editable script to set the persistent variables as a one-off.

I've assumed above that requesting the value of a variable that hasn't been set would return a blank string, but the code could easily be adapted to use, for example, a try block:

try
	set dateFormat to get_string_variable "dateFormatSmall"
catch
	set dateFormat to "h:mm a"
	set_persistent_string_variable "dateFormatSmall" to dateFormat
end try

Hang on. I've been looking at that code a bit more closely and I think I see some more issues. I'll dig a bit deeper and get back to you...

1 Like

Haha, no worries. Thank you for the help! You're correct that it assumes "dynamic" if the variable is missing value. EDIT: Derp now I see what you're trying to do for upgrading, great idea.

@bello2185 yeah, I'll stick a 12/24hr switch in there. Probably not for the next version but the one after :slight_smile:

Also, fixed the esc key issue in the next version. I have no idea why it was set to show icon only.

1 Like

I noticed a couple of issues where there's a path through the code that ends up using a variable that hasn't been set - stuff like that.

You'll have to excuse me, though: I'm about 10 years out of practice at this coding lark and, even then, I was C++, not AppleScript. So I may keep changing my mind over suggestions.

I think you're right about persisting the settings across updates. It does make me think of a separate executable for configuring all the GC-BTT settings - something that would be a bit more flexible than trying to do it through the touch bar.

The thing with 12/24 hour is that it's not just that: there's also date order (date-month vs month-date) and possibly other factors that are unique to certain places. Tom Scott has a great video on YouTube from a few years back that goes into the nightmare that is internationalisation (--zation).

That's why I think a separate configurator app might help, so that the user can enter the strings they want and you don't have to keep bloating the code with different options.

1 Like

As if to prove myself right, forget the changes I made above - I was getting a bit lost on what the code was trying to do. There are still some issues but I need to do a bit more thinking. For now, though, the dog needs a long walk and I need some coffee...

1 Like

So I am a big Zoom.us user, however when trying to use the mute button from GC... it doesnt actually work. I am never muted or unmuted.

If Zoom.us is as notorious as other videoconferencing apps, it probably isn't using the system setting for microphone input. GC-BTT's key only mutes the currently selected input, so make sure the microphone Zoom is using matches.

yeah its set to use System Default

kk, I'll look into this soon then :slight_smile:

Yeah.. much better shortcut in my opinion =)

I don't know what happened but GC setting's a bit odd.. I can't seem to modify it in this version

You need to first remove ALL previous versions of GC-BTT, otherwise the settings won't be able to find the right buttons to update.

although, none is active?

Yes, because the old buttons still exist they are taking up the ID's that the new buttons want. So you have to completely remove all old versions first.

@Andreas_Hegenberg not sure how much louder I can scream for a workaround to this issue :stuck_out_tongue: people think it's a bug, which means for all practical purposes it is a bug.

2 Likes