Modify

Opened 18 years ago

Closed 18 years ago

#230 closed Bug (Fixed)

Wrong GuiCtrlSetResizing after ControlMove in GUIs with Menus

Reported by: anonymous Owned by: J-Paul Mesnage
Milestone: 3.2.11.11 Component: AutoIt
Version: 3.2.11.10 Severity: None
Keywords: Cc:

Description

Probably related to the fixed #214 ticket.
After moving controls with ControlMove in a GUI with menus, the height of the controls using $GUI_DOCKBOTTOM is increased at next GUI resize event.

#include <GuiConstantsEx.au3>
#include <WindowsConstants.au3>
$GUI = GUICreate("GuiCtrlSetResizing and ControlMove in GUIs with menus (beta v3.2.11.10)", 600, 300, -1, -1, BitOR($WS_MINIMIZEBOX, $WS_CAPTION, $WS_POPUP, $WS_SYSMENU,$WS_SIZEBOX))

$cListView = GUICtrlCreateListView("H1|H2", 0,0,400,200)
GuiCtrlSetResizing($cListView, $GUI_DOCKLEFT+$GUI_DOCKTOP+$GUI_DOCKRIGHT+$GUI_DOCKBOTTOM)

$s_text='1. Resize GUI and notice the resizing of listview.' & @LF & @LF & _ 
  '2. Press the ControlMove button to reposition the ListView Control (with ControlMove) and update its resizing (with GuiCtrlSetResizing).' & _ 
  @LF & @LF & '3. Resize horizontally the GUI and notice that the listview height is increased (probably by the size of menu bar)' & _
  @LF & @LF & '4. Repeat steps 2 and 3.'
$c_lbl = GUICtrlCreateLabel($s_text, 420,10,170,210)
GuiCtrlSetResizing($c_lbl, $GUI_DOCKRIGHT+$GUI_DOCKTOP+$GUI_DOCKWIDTH+$GUI_DOCKHEIGHT)

$c_btn_CtrlMove = GUICtrlCreateButton("ControlMove", 420,230,80,20)
GuiCtrlSetResizing($c_btn_CtrlMove, $GUI_DOCKRIGHT+$GUI_DOCKTOP+$GUI_DOCKWIDTH+$GUI_DOCKHEIGHT)

$cMenu=GuiCtrlCreateMenu("MENU")
GUISetState()


While 1
    $msg = GUIGetMsg()
    Switch $msg
        Case $GUI_EVENT_CLOSE
            Exit
			
		Case $c_btn_CtrlMove
			ControlMove('','',$cListView, 0, 0)
			GuiCtrlSetResizing($cListView, $GUI_DOCKLEFT+$GUI_DOCKTOP+$GUI_DOCKRIGHT+$GUI_DOCKBOTTOM)
    EndSwitch
WEnd

Attachments (0)

Change History (1)

comment:1 by J-Paul Mesnage, 18 years ago

Milestone: 3.2.11.11
Owner: set to J-Paul Mesnage
Resolution: Fixed
Status: newclosed

Fixed in version: 3.2.11.11

Modify Ticket

Action
as closed The owner will remain J-Paul Mesnage.

Add Comment


E-mail address and name can be saved in the Preferences .
 
Note: See TracTickets for help on using tickets.