dongaman Posted January 14, 2010 Posted January 14, 2010 That may be complicated, sorry my poor nonnative english I build a GUI app with many functions.And i set GUIOnEventMode to 1.In the main gui,I use while(1)and sleep(1000) to loop the gui. My QUESTION is: Wether any other function i will be paused or to be unstable while the dead loop in main gui sleeping? BECAUSE: 1 The function i defined have some while(1) loop to receive console application's output. 2 The console app is child app created from my main gui app.
KaFu Posted January 14, 2010 Posted January 14, 2010 No , sleeps in the main loop should have no influence on the functions if you utilize OnEventMode. OS: Win10-22H2 - 64bit - German, AutoIt Version: 3.3.16.1, AutoIt Editor: SciTE, Website: https://funk.eu AMT - Auto-Movie-Thumbnailer (2024-Oct-13) BIC - Batch-Image-Cropper (2023-Apr-01) COP - Color Picker (2009-May-21) DCS - Dynamic Cursor Selector (2024-Oct-13) HMW - Hide my Windows (2024-Oct-19) HRC - HotKey Resolution Changer (2012-May-16) ICU - Icon Configuration Utility (2018-Sep-16) SMF - Search my Files (2024-Oct-20) - THE file info and duplicates search tool SSD - Set Sound Device (2017-Sep-16)
dongaman Posted January 14, 2010 Author Posted January 14, 2010 But I found nothing about sleep's 'bad smell' in autoit help doc.
KaFu Posted January 14, 2010 Posted January 14, 2010 But I found nothing about sleep's 'bad smell' in autoit help doc.Sorry, I don't understand your question. OS: Win10-22H2 - 64bit - German, AutoIt Version: 3.3.16.1, AutoIt Editor: SciTE, Website: https://funk.eu AMT - Auto-Movie-Thumbnailer (2024-Oct-13) BIC - Batch-Image-Cropper (2023-Apr-01) COP - Color Picker (2009-May-21) DCS - Dynamic Cursor Selector (2024-Oct-13) HMW - Hide my Windows (2024-Oct-19) HRC - HotKey Resolution Changer (2012-May-16) ICU - Icon Configuration Utility (2018-Sep-16) SMF - Search my Files (2024-Oct-20) - THE file info and duplicates search tool SSD - Set Sound Device (2017-Sep-16)
dongaman Posted January 14, 2010 Author Posted January 14, 2010 'bad smell' means influence. I used this c++ terms
KaFu Posted January 14, 2010 Posted January 14, 2010 'bad smell' means influence. I used this c++ terms Oh, I see . Sleep in the main loop can't interfere with your functions as AutoIt is a single-threaded language (@usual suspects: bash me for wrong wording , pllleeeease ). When you call a function via OnEvent the single main thread's working on that function and will never call the main loop until the function returns. OS: Win10-22H2 - 64bit - German, AutoIt Version: 3.3.16.1, AutoIt Editor: SciTE, Website: https://funk.eu AMT - Auto-Movie-Thumbnailer (2024-Oct-13) BIC - Batch-Image-Cropper (2023-Apr-01) COP - Color Picker (2009-May-21) DCS - Dynamic Cursor Selector (2024-Oct-13) HMW - Hide my Windows (2024-Oct-19) HRC - HotKey Resolution Changer (2012-May-16) ICU - Icon Configuration Utility (2018-Sep-16) SMF - Search my Files (2024-Oct-20) - THE file info and duplicates search tool SSD - Set Sound Device (2017-Sep-16)
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now