• Products
    • Isadora
    • Get It
    • ADD-ONS
    • IzzyCast
    • Get It
  • Forum
  • Help
  • Werkstatt
  • Newsletter
  • Impressum
  • Dsgvo
  • Press
  • Isadora
  • Get It
  • ADD-ONS
  • IzzyCast
  • Get It
  • Press
  • Dsgvo
  • Impressum

Navigation

    • Register
    • Login
    • Search
    • Categories
    • Recent
    • Popular
    • Tags

    [SOLVED] Avoiding “Save project” and “Delete Captured Media” when closing project

    How To... ?
    5
    20
    2914
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • Woland
      Woland Tech Staff @Michel last edited by

      @michel said:

      on a mac you could record a mouse movement with automator. So it would click automatically to not safe the movies or the project.

      Easier than this (and safer in case the resolution changed or the dialog showed up somewhere different) is using Automator with a timed event that just tells Isadora to forcequit. (There's also multiple ways to do all this so google is your friend to find other Applescript + timed event + forcequit options.)

      Simple script (without the timed event bit) would be: 

      tell application "Isadora" to quit saving no

      or

      tell application "Isadora 3" to quit saving no"

      You can also go the route of having Applescript press specific buttons on specific dialogs or simulate the necessary keypresses for forcequitting.

      TroikaTronix Technical Support
      New Support Ticket: https://support.troikatronix.com/support/tickets/new
      Support Policy: https://support.troikatronix.com/support/solutions/articles/13000064762
      Add-Ons: https://troikatronix.com/add-ons/ & https://troikatronix.com/add-ons/?u=woland
      Professional Services: https://support.troikatronix.com/support/solutions/articles/13000109444

      | Isadora Version: all of them | Mac Pro (Late 2013), macOS 10.14.6, 3.5GHz 6-core, 1TB SSD, 64GB RAM, Dual AMD FirePro D700s |

      1 Reply Last reply Reply Quote 0
      • mark
        mark last edited by Woland

        Here's another solution I did last night that presses the buttons of the dialog for you. It's useful to note that almost any macOS app's dialogs, menus, etc. can be scripted by sending messages to System Events, as @Michel pointed out in his link above.

        This script is directly aimed at the issue brought up by the original poster. It assumes the following:

        1) The Isadora file is "dirty" -- meaning it will ask to save the file. (Always true if you've recorded at movie using Capture Stage to Movie or Capture Camera to Movie)
        2) The "Do you want to delete captured media" dialog will appear.  (Always true if you've recorded at movie using Capture Stage to Movie or Capture Camera to Movie)

        Again, this is for AppleScript and thus a MacOS only solution. I don't know of an equivlent on Windows, though maybe @DusX does.

        -------- APPLESCRIPT STARTS HERE --------

        tell application "System Events"
        tell application "Isadora"
        activate
        end tell
        tell process "Isadora"
        -- after a short delay, click the close button in the window
        delay 0.5
        click button 3 of window 1
        -- after a short delay, click the "Yes" button of the "Save Captured Media" warning
        -- this will delete all of the captured media
        delay 0.5
        click button "Yes" of window 1
        -- after a short delay, click the "Don't Save" button of the "Save File" warning sheet
        delay 0.5
        click button 2 of sheet 1 of window 1
        end tell
        end tell

        -------- APPLESCRIPT ENDS HERE --------

        Best Wishes,
        Mark

        Media Artist & Creator of Isadora
        Macintosh SE-30, 32 Mb RAM, MacOS 7.6, Dual Floppy Drives

        Woland 1 Reply Last reply Reply Quote 1
        • Woland
          Woland Tech Staff @mark last edited by

          Mark'sCloseNoSave.scpt.zip

          TroikaTronix Technical Support
          New Support Ticket: https://support.troikatronix.com/support/tickets/new
          Support Policy: https://support.troikatronix.com/support/solutions/articles/13000064762
          Add-Ons: https://troikatronix.com/add-ons/ & https://troikatronix.com/add-ons/?u=woland
          Professional Services: https://support.troikatronix.com/support/solutions/articles/13000109444

          | Isadora Version: all of them | Mac Pro (Late 2013), macOS 10.14.6, 3.5GHz 6-core, 1TB SSD, 64GB RAM, Dual AMD FirePro D700s |

          1 Reply Last reply Reply Quote 0
          • L
            Lauri last edited by

            @mark @Woland @Michel Thousand thanks for your replies!

            I tried the script but running it gets the following error: error "System Events got an error: Script Editor is not allowed assistive access." number -1719 from window 1 of process "Isadora".

            So, what I did (after having run my patch with capturing stage) was quitting Isadora (then the first pop-up comes up) and then running Mark'sCloseNoSave.scpt, resulting to the above error message in script editor.

            When quitting my project (as initially described), it brings two pop-ups:

            In this order. And the marked buttons are the ones I want. So, don't delete files and don't save the project.

            Thanks again!

            MacPro (2013), 3.0GHz 8-Core Intel Xeon E5, RAM 64GB, Dual AMB FirePro D700, OSX 10.13.6
            MacBookPro (15 inch 2018), 2.6 GHz Intel Core i7, RAM 32GB, Radeon Pro Vega 20, OSX 10.14.6

            1 Reply Last reply Reply Quote 0
            • Woland
              Woland Tech Staff last edited by Woland

              @lauri said:

              Script Editor is not allowed assistive access

               Google is your friend: https://stackoverflow.com/questions/31019916/is-not-allowed-for-assistive-access-error-when-running-applescript-from-java

              TroikaTronix Technical Support
              New Support Ticket: https://support.troikatronix.com/support/tickets/new
              Support Policy: https://support.troikatronix.com/support/solutions/articles/13000064762
              Add-Ons: https://troikatronix.com/add-ons/ & https://troikatronix.com/add-ons/?u=woland
              Professional Services: https://support.troikatronix.com/support/solutions/articles/13000109444

              | Isadora Version: all of them | Mac Pro (Late 2013), macOS 10.14.6, 3.5GHz 6-core, 1TB SSD, 64GB RAM, Dual AMD FirePro D700s |

              1 Reply Last reply Reply Quote 0
              • Woland
                Woland Tech Staff last edited by

                Try tweaking this version

                LWSQuitKeepMediaNoSave.scpt.zip

                An easy way to actually see what's happening is to slow it all down by changing each "delay 0.5" to "delay 2" so each action takes longer.

                TroikaTronix Technical Support
                New Support Ticket: https://support.troikatronix.com/support/tickets/new
                Support Policy: https://support.troikatronix.com/support/solutions/articles/13000064762
                Add-Ons: https://troikatronix.com/add-ons/ & https://troikatronix.com/add-ons/?u=woland
                Professional Services: https://support.troikatronix.com/support/solutions/articles/13000109444

                | Isadora Version: all of them | Mac Pro (Late 2013), macOS 10.14.6, 3.5GHz 6-core, 1TB SSD, 64GB RAM, Dual AMD FirePro D700s |

                Michel 1 Reply Last reply Reply Quote 0
                • Michel
                  Michel Izzy Guru @Woland last edited by

                  @woland @Lauri 

                  there is an error in the code edited it: LWSQuitKeepMediaNoSave2.scpt.zip

                  Best Michel

                  Michel Weber | www.filmprojekt.ch | rMBP (2019) i9, 16gig, AMD 5500M 8 GB, OS X 10.15 | located in Winterthur Switzerland.

                  Woland 1 Reply Last reply Reply Quote 1
                  • Woland
                    Woland Tech Staff @Michel last edited by

                    @michel said:

                    there is an error in the code

                     No surprise there. I write frankenstein applescript cobbled together from different places and then just tweak things until it does what I want. Couldn't test that one in full because I'm on the orders computer which doesn't have a license different dialogs show up when quitting Isadora.

                    Also worth noting that you'll need to change the name of the Isadora application specified at the top when you move to different versions.

                    Best wishes,

                    Woland

                    TroikaTronix Technical Support
                    New Support Ticket: https://support.troikatronix.com/support/tickets/new
                    Support Policy: https://support.troikatronix.com/support/solutions/articles/13000064762
                    Add-Ons: https://troikatronix.com/add-ons/ & https://troikatronix.com/add-ons/?u=woland
                    Professional Services: https://support.troikatronix.com/support/solutions/articles/13000109444

                    | Isadora Version: all of them | Mac Pro (Late 2013), macOS 10.14.6, 3.5GHz 6-core, 1TB SSD, 64GB RAM, Dual AMD FirePro D700s |

                    1 Reply Last reply Reply Quote 0
                    • L
                      Lauri last edited by

                      @Michel @Woland Thousand thanks again! 

                      Great! Michel's (...NoSave2.scpt) version work well!!!

                      And thanks for noting about the Accessibility section, I had ScriptEditor in the list but had forgotten to checkmark it. Sorry, my fault.

                      ---

                      Well, another question, would there be any way to launch the script from Isadora? (Just figuring out simple/secure ways to handle timing.)

                      To preserve the functionality of my patch, the Stage Captures have to run a certain length, so closing the patch is triggered when the capture has ended (and then the patch jumps to an empty stage, and Isadora can then be closed). Ending the patch/captures is easy to get timed within Isadora, but it would be convenient to launch the closing script from the same timing. Of course there could be a reasonable time difference from estimated patch ending and script launch, but it would be nice if launching the script could be initiated from Isadora. Possible?

                      Thanks!

                      MacPro (2013), 3.0GHz 8-Core Intel Xeon E5, RAM 64GB, Dual AMB FirePro D700, OSX 10.13.6
                      MacBookPro (15 inch 2018), 2.6 GHz Intel Core i7, RAM 32GB, Radeon Pro Vega 20, OSX 10.14.6

                      mark 1 Reply Last reply Reply Quote 1
                      • mark
                        mark @Lauri last edited by mark

                        @lauri said:

                        Well, another question, would there be any way to launch the script from Isadora? (Just figuring out simple/secure ways to handle timing.)

                        I'm afraid, for security reasons, we don't allow that. Otherwise someone evil could launch an AppleScript to do nasty things to your computer, e.g., erase your hard drive.

                        You can however write applescripts that monitor the contents of a folder, looking for a file to appear. So one way would be to use the Data Array actor to write a file  to disk -- even if the file has no actual contents. When the AppleScript sees that file appear in the folder, it could then do something else. So that's one way to trigger an AppleScript from Isadora.

                        I'm sorry but I don't have time at the moment to write this for you. But if you want to try yourself, read this Apple article on "Folder Actions."

                        Best Wishes,
                        Mark

                        Media Artist & Creator of Isadora
                        Macintosh SE-30, 32 Mb RAM, MacOS 7.6, Dual Floppy Drives

                        1 Reply Last reply Reply Quote 0
                        • L
                          Lauri last edited by

                          @mark Thousand thanks for your advice!  Great! I will look into it.

                          MacPro (2013), 3.0GHz 8-Core Intel Xeon E5, RAM 64GB, Dual AMB FirePro D700, OSX 10.13.6
                          MacBookPro (15 inch 2018), 2.6 GHz Intel Core i7, RAM 32GB, Radeon Pro Vega 20, OSX 10.14.6

                          1 Reply Last reply Reply Quote 0
                          • Woland
                            Woland Tech Staff last edited by

                            The other thing you could do is make the applescript into an .app file, make it a startup item, have it open Isadora and use the time of day function to trigger the closing and opening of Isadora at whatever time intervals you want.

                            TroikaTronix Technical Support
                            New Support Ticket: https://support.troikatronix.com/support/tickets/new
                            Support Policy: https://support.troikatronix.com/support/solutions/articles/13000064762
                            Add-Ons: https://troikatronix.com/add-ons/ & https://troikatronix.com/add-ons/?u=woland
                            Professional Services: https://support.troikatronix.com/support/solutions/articles/13000109444

                            | Isadora Version: all of them | Mac Pro (Late 2013), macOS 10.14.6, 3.5GHz 6-core, 1TB SSD, 64GB RAM, Dual AMD FirePro D700s |

                            mark 1 Reply Last reply Reply Quote 0
                            • mark
                              mark @Woland last edited by

                              @woland said:

                              The other thing you could do is make the applescript into an .app file, make it a startup item, have it open Isadora and use the time of day function to trigger the closing and opening of Isadora at whatever time intervals you want.

                               Also an excellent and probably easier suggestion if it works for you @Lauri 

                              Best Wishes,
                              Mark

                              Media Artist & Creator of Isadora
                              Macintosh SE-30, 32 Mb RAM, MacOS 7.6, Dual Floppy Drives

                              1 Reply Last reply Reply Quote 0
                              • L
                                Lauri last edited by

                                @Woland @mark Thank you again for your replies!

                                Yes (AppleScript as an .app and make it as a startup item), that’s the way I usually have dealt with the installation projects.

                                The thing is that I need to sync the close-down with the stage captures. The captures really need to be fixed length, so an arbitrary shut-down doesn’t work. 

                                But yes, I can initiate also the close-down Isadora procedure by sending a timed key (for instance “X”) from the AppleScript app (registered by Key Table Watcher actor, which triggers the close-down procedure), and then make the AppleScript app wait for at least the length of the capture cycle, before closing the project/Isadora – not deleting files, not saving patch. (So, all the timing would actually come from the AppleScript app.)

                                Thanks again!

                                MacPro (2013), 3.0GHz 8-Core Intel Xeon E5, RAM 64GB, Dual AMB FirePro D700, OSX 10.13.6
                                MacBookPro (15 inch 2018), 2.6 GHz Intel Core i7, RAM 32GB, Radeon Pro Vega 20, OSX 10.14.6

                                mark 1 Reply Last reply Reply Quote 0
                                • mark
                                  mark @Lauri last edited by

                                  @lauri said:

                                  But yes, I can initiate also the close-down Isadora procedure by sending a timed key (for instance “X”) from the AppleScript app (registered by Key Table Watcher actor, which triggers the close-down procedure), and then make the AppleScript app wait for at least the length of the capture cycle, before closing the project/Isadora – not deleting files, not saving patch. (So, all the timing would actually come from the AppleScript app.)

                                   Excellent Idea. Let us know if it works!

                                  Media Artist & Creator of Isadora
                                  Macintosh SE-30, 32 Mb RAM, MacOS 7.6, Dual Floppy Drives

                                  1 Reply Last reply Reply Quote 0
                                  • First post
                                    Last post