Jump to content



Photo

GUICtrlDelete with GUICtrlCreateTab;deletes controls in other GUIs


  • Please log in to reply
2 replies to this topic

#1 DarkTurok

DarkTurok

    Seeker

  • New Members
  • 3 posts

Posted 02 January 2008 - 09:29 PM

There seems to be a problem when deleting a Tab-control. As shown in the repcase below, deleting a control created with GuiCtrlCreateTab will also delete controls in a different GUI.

Using AutoIt 3.2.10.0

AutoIt         
#include <GUIConstants.au3> GUICreate("Repcase 1",220,100, 100,200) $progressbar1 = GUICtrlCreateProgress (10,10,200,20) $progressbar2 = GUICtrlCreateProgress (10,40,200,20,$PBS_SMOOTH) GUISetState() GUICreate( "Repcase 2",220,100, 340,200) $tab = GUICtrlCreateTab( 1, 1, 100, 50 ) $ti = GUICtrlCreateTabItem( "Test" ) GUICtrlCreateLabel( "Label", 10, 30, 50, 20 ) GUICtrlCreateTabItem( "" ) GUISetState() MsgBox( 0, "Info", "Everything looks fine" ) ; when you un-comment the line below the control-deletion works fine ; GUICtrlDelete( $ti ) GUICtrlDelete( $tab ) MsgBox( 0, "Error", "And now the second progess-bar is gone" )






#2 MrCreatoR

MrCreatoR

    Must AutoIt!

  • MVPs
  • 3,241 posts

Posted 03 January 2008 - 12:24 AM

Strange indeed... and it seems that it happend only with first two controls, and with two GUI windows, and the control is really deleted...

#include <GUIConstants.au3> $Gui = GUICreate("Repcase 1",220,100, 100,200) GUICtrlCreateLabel("Label", 10, 10) GUICtrlCreateCheckbox("Checkbox", 10, 40) GUISetState() GUICreate("Repcase 2", 220, 100, 340, 200) $Tab = GUICtrlCreateTab(1, 1) $TabItem = GUICtrlCreateTabItem("Item") GUICtrlCreateTabItem("") GUISetState() ;GUICtrlDelete($TabItem) GUICtrlDelete($Tab) MsgBox(0, "", WinGetClassList($Gui)) ;here we see that in the first gui there only one class of control


Btw, the bug is reproducable even with AutoIt 3.2.8.1.
Using OS: Win 7 Professional, Using AutoIt Ver(s): 3.3.6.1 / 3.3.8.1

Posted Image AutoIt Russian CommunityPosted Image Projects: ATT - Application Translate Tool [new] | BlockIt - Block files & folders [new] | SIP - Selected Image Preview [new] | SISCABMAN - SciTE Abbreviations Manager [new] | AutoIt Path Switcher | AutoIt Menu for Opera! | YouTube Download Center! | Desktop Icons Restorator | Math Tasks | KeyBoard & Mouse Cleaner | CaptureIt - Capture Images Utility | CheckFileSize ProgramPosted Image UDFs: OnAutoItErrorRegister - Handle AutoIt critical errors [new] | AutoIt Syntax Highlight [new] | Opera Library! | Winamp Library | GetFolderToMenu | Custom_InputBox()! | _FileRun UDF | _CheckInput() UDF | _GUIInputSetOnlyNumbers() UDF | _FileGetValidName() UDF | _GUICtrlCreateRadioCBox UDF | _GuiCreateGrid() | _PathSplitByRegExp() | _GUICtrlListView_MoveItems - UDF | GUICtrlSetOnHover_UDF! | _ControlTab UDF! | _MouseSetOnEvent() UDF! | _ProcessListEx - UDF | GUICtrl_SetResizing - UDF! | Mod. for _IniString UDFs | _StringStripChars UDF | _ColorIsDarkShade UDF | _ColorConvertValue UDF | _GUICtrlTab_CoverBackground | CUI_App_UDF | _IncludeScripts UDF | _AutoIt3ExecuteCode | _DragList UDF | Mod. for _ListView_Progress | _ListView_SysLink | _GenerateRandomNumbers | _BlockInputEx | _IsPressedEx | OnAutoItExit Handler | _GUICtrlCreateTFLabel UDF | WinControlSetEvent UDF | Mod. for _DirGetSizeEx UDFPosted Image Examples: ScreenSaver Demo - Matrix included | Gui Drag Without pause the script | _WinAttach()! | Turn Off/On Monitor | ComboBox Handler Example | Mod. for "Thinking Box" | Cool "About" Box | TasksBar Imitation DemoLike the examples/UDFs? Please rate the topic (up-right corner of the post header: Rating Posted Image)* === My topics === *

==========================================================Posted Image==========================================================

AutoIt is simple, subtle, elegant. © AutoIt Team


#3 jpm

jpm

    a Real GUI/debug lover

  • Developers
  • 8,925 posts

Posted 04 January 2008 - 12:11 AM

Thanks,
Fixed 3.2.11.0
PS very old bug since Jon introduce multiple GUI !!!




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users