Jump to content

Script becomes way slower after a msgbox - (Moved)


Recommended Posts

8 hours ago, Jon said:

Reuploaded the test exes. Should be no slowdowns with GuiOnEventMode or TrayOnEventMode now.

;~  ---------------------------
;~  test_beta.au3 v3.3.14.5
;~  ---------------------------
;~  @@ Debug(12) : TimerDiff($start) = 145.6027  GUIOnEventMode = 0
;~  @@ Debug(20) : TimerDiff($start) = 1775.5734     GUIOnEventMode = 0
;~  @@ Debug(12) : TimerDiff($start) = 1967.2883     GUIOnEventMode = 1
;~  @@ Debug(20) : TimerDiff($start) = 1963.5744     GUIOnEventMode = 1

;~  ---------------------------
;~  test_beta.au3 v3.3.15.1 (2020-05-01)
;~  ---------------------------
;~  @@ Debug(12) : TimerDiff($start) = 108.2709  GUIOnEventMode = 0
;~  @@ Debug(20) : TimerDiff($start) = 126.4575  GUIOnEventMode = 0
;~  @@ Debug(12) : TimerDiff($start) = 318.5004  GUIOnEventMode = 1
;~  @@ Debug(20) : TimerDiff($start) = 365.3123  GUIOnEventMode = 1

;~ ---------------------------
;~ test_beta.au3 v3.3.15.1 (2020-05-02 17:21)
;~ ---------------------------
;~ @@ Debug(12) : TimerDiff($start) = 124.0051   GUIOnEventMode = 0
;~ @@ Debug(20) : TimerDiff($start) = 147.8302   GUIOnEventMode = 0
;~ @@ Debug(12) : TimerDiff($start) = 131.6802   GUIOnEventMode = 1
;~ @@ Debug(20) : TimerDiff($start) = 129.3251   GUIOnEventMode = 1

:D

Follow the link to my code contribution ( and other things too ).
FAQ - Please Read Before Posting.
autoit_scripter_blue_userbar.png

Link to comment
Share on other sites

On 5/2/2020 at 12:55 PM, Nine said:

The display is not performed correctly :

the "-1" does not. So in that regard, yes. Otherwise it shows ( if the "default" is not used but the size is declared ). 
Strange, as the change should not have affected that :( 

PS: the mishap was yesterday in the first beta. So is not a today edit.

Edited by argumentum

Follow the link to my code contribution ( and other things too ).
FAQ - Please Read Before Posting.
autoit_scripter_blue_userbar.png

Link to comment
Share on other sites

I just redownloaded the exe, in case I missed one change.  The problem persist both x86 and x64, and both W7 and W10.  When I use non-beta it works fine, but if I use the beta exe the tree is shrunk.  But like it was said earlier, replacing default size values (-1) by actual size, solves the problem.

Link to comment
Share on other sites

  • Administrators

@Jos Seems to be revision 12222: Fixed #2962: GUICtrlSetImage() on GUICtrlCreatePIC() with $SS_SUNKEN or WS_EX_DLGMODALFRAME

Not sure why that change has broken this script, or if this script is wrong. The source change from that revision was changing

nStyle = ResolveGroupStyle(nStyle | SS_BITMAP);

to 

nStyle = ResolveGroupStyle(nStyle | SS_BITMAP | SS_CENTERIMAGE);

 

Link to comment
Share on other sites

small problem - if run from SciTE, TrayGetMsg ( ) crush script with error:

+>13:34:01 AU3Check ended.rc:0
>Running:(3.3.15.1):C:\Program Files (x86)\AutoIt3\autoit3.exe "c:\program files (x86)\AutoIt3\Examples\Helpfile\TrayGetMsg.au3"    
--> Press Ctrl+Alt+Break to Restart or Ctrl+Break to Stop
!>13:34:02 AutoIt3.exe ended.rc:-1073741819
+>13:34:02 AutoIt3Wrapper Finished.
>Exit code: 3221225477    Time: 0.6698

if compiled - it runs OK, but in "About" MSGBox autoit version 3.3.14.0 is shown... (I'm only replaced autoit exe-s)

#NoTrayIcon
#include <MsgBoxConstants.au3>
#include <TrayConstants.au3> ; Required for the $TRAY_ICONSTATE_SHOW constant.

Opt("TrayMenuMode", 3) ; The default tray menu items will not be shown and items are not checked when selected. These are options 1 and 2 for TrayMenuMode.

Example()

Func Example()
    Local $idAbout = TrayCreateItem("About")
    TrayCreateItem("") ; Create a separator line.

    Local $idExit = TrayCreateItem("Exit")

    TraySetState($TRAY_ICONSTATE_SHOW) ; Show the tray menu.

    While 1
        Switch TrayGetMsg()
            Case $idAbout ; Display a message box about the AutoIt version and installation path of the AutoIt executable.
                MsgBox($MB_SYSTEMMODAL, "", "AutoIt tray menu example." & @CRLF & @CRLF & _
                        "Version: " & @AutoItVersion & @CRLF & _
                        "Install Path: " & StringLeft(@AutoItExe, StringInStr(@AutoItExe, "\", 0, -1) - 1)) ; Find the folder of a full path.

            Case $idExit ; Exit the loop.
                ExitLoop
        EndSwitch
    WEnd
EndFunc   ;==>Example

 

 

Link to comment
Share on other sites

  • Moderators

Iczer,

Thanks. We know about that one - Jon is working on it.

M23

Public_Domain.png.2d871819fcb9957cf44f4514551a2935.png Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind

Open spoiler to see my UDFs:

Spoiler

ArrayMultiColSort ---- Sort arrays on multiple columns
ChooseFileFolder ---- Single and multiple selections from specified path treeview listing
Date_Time_Convert -- Easily convert date/time formats, including the language used
ExtMsgBox --------- A highly customisable replacement for MsgBox
GUIExtender -------- Extend and retract multiple sections within a GUI
GUIFrame ---------- Subdivide GUIs into many adjustable frames
GUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView items
GUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeView
Marquee ----------- Scrolling tickertape GUIs
NoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxes
Notify ------------- Small notifications on the edge of the display
Scrollbars ----------Automatically sized scrollbars with a single command
StringSize ---------- Automatically size controls to fit text
Toast -------------- Small GUIs which pop out of the notification area

 

Link to comment
Share on other sites

On 5/5/2020 at 5:54 AM, Melba23 said:

We know about that one - Jon is working on it.

Sorry to insist, but the new exe are terribly fantastic.  Is there a chance that this problem be solved in short term.  Because, it is a very hard dilemma  to choose between the old slow version with no problem with SciTE TrayGetMsg ( ), and the new ones.

Link to comment
Share on other sites

  • Developers
9 hours ago, Nine said:

Sorry to insist, but the new exe are terribly fantastic.  Is there a chance that this problem be solved in short term.  Because, it is a very hard dilemma  to choose between the old slow version with no problem with SciTE TrayGetMsg ( ), and the new ones.

Try the current Beta to see whether that fixes it as I believe there was an update without upping the versionnumber. 

Jos

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Link to comment
Share on other sites

  • Moderators

Nine, 

I have just downloaded the Beta Autoit3.exe file from Jon's link and TrayGetMsg works just fine for me using Iczer's script above.

M23

Public_Domain.png.2d871819fcb9957cf44f4514551a2935.png Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind

Open spoiler to see my UDFs:

Spoiler

ArrayMultiColSort ---- Sort arrays on multiple columns
ChooseFileFolder ---- Single and multiple selections from specified path treeview listing
Date_Time_Convert -- Easily convert date/time formats, including the language used
ExtMsgBox --------- A highly customisable replacement for MsgBox
GUIExtender -------- Extend and retract multiple sections within a GUI
GUIFrame ---------- Subdivide GUIs into many adjustable frames
GUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView items
GUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeView
Marquee ----------- Scrolling tickertape GUIs
NoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxes
Notify ------------- Small notifications on the edge of the display
Scrollbars ----------Automatically sized scrollbars with a single command
StringSize ---------- Automatically size controls to fit text
Toast -------------- Small GUIs which pop out of the notification area

 

Link to comment
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...