How can i hide a list box, correctly?

For questions about using Classic.

Post » Tue Jul 19, 2011 10:08 pm

In my game i currently use:

Set X to Window.X-(Items.Width)-10 (to hide the list boxes)

Set X Window.ClientX+24   (to reposition the list boxes)

This WORKS fine.....but if i want to drag the game window to another position, the listboxes reappear on the left edge and move across the screen as i am dragging the window?

I have the game window set to position (0,0) on start of layout.
my game is 800x600
my display is 1024x768

Anybody know why.
B
20
S
6
G
7
Posts: 1,214
Reputation: 7,341

Post » Tue Jul 19, 2011 10:36 pm

The listbox's position is already relative to the window. The "Window.X" is not needed.
To hide or move off the visible window:
-> ListBox: Set X to 0-ListBox.Width

To show:
-> ListBox: Set X to 24
B
83
S
27
G
69
Posts: 4,902
Reputation: 48,971

Post » Tue Jul 19, 2011 11:49 pm

Thanks a lot Rojohound.
B
20
S
6
G
7
Posts: 1,214
Reputation: 7,341


Return to Help & Support using Construct Classic

Who is online

Users browsing this forum: No registered users and 1 guest