Skip to content

Comments

Don't relaunch a program if user chooses "not now"#638

Merged
scriptingosx merged 4 commits intoInstallomator:devfrom
dnikles:dont_reopen_not_now
Jan 6, 2023
Merged

Don't relaunch a program if user chooses "not now"#638
scriptingosx merged 4 commits intoInstallomator:devfrom
dnikles:dont_reopen_not_now

Conversation

@dnikles
Copy link
Contributor

@dnikles dnikles commented Aug 3, 2022

Current behavior will "launch" a program when the user selects "not now", even though the program was never closed, which brings a program the user may not be working in to the front. This change sets appClosed to 0 if the user chooses not now, and therefore does not close the app. The end result is if a user selects not now, that program is not brought to the front.

dnikles added 3 commits August 3, 2022 12:39
Current behavior will "launch" a program when the user selects "not now", even though the program was never closed, which brings a program the user may not be working in to the front. This change checks for that error "10", and if so, it will not run the reopenCLosedProcess function. The end result is if a user selects not now, that program is not brought to the front.
This is cleaner than my earlier commit. appClosed is set to 1 before the app is actually closed. If we defer, set appClosed to something other than 1. The function that calls to reopen the app checks if it is set to 1, so setting it to 0 prevents the app from opening, and will appropriately log " App not closed, so no reopen."
@dnikles dnikles closed this by deleting the head repository Oct 4, 2022
@dnikles dnikles reopened this Oct 4, 2022
@scriptingosx scriptingosx added this to the v11 milestone Nov 18, 2022
@scriptingosx scriptingosx changed the base branch from main to dev January 6, 2023 13:55
@scriptingosx scriptingosx merged commit fc7ab6b into Installomator:dev Jan 6, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants