3d2d-vgui icon indicating copy to clipboard operation
3d2d-vgui copied to clipboard

DComboBox

Open chudders1231 opened this issue 6 years ago • 4 comments

Hey matt, This 2D3D VGUI script is perfect for me right now because i need this sort of interaction on a panel im using for entities however i have found that DComboBoxes don't stick to the the parent frame when it is open and the options aren't displayed on the 3D2D panel, instead they throw an error and display on your screen instead. How would this be fixed?

http://prntscr.com/kd27y4

The error:

[ERROR] lua/vgui/dmenu.lua:185: attempt to call field 'PerformLayout' (a nil value)

  1. PerformLayout - lua/vgui/dmenu.lua:185
  2. unknown - lua/vgui/dscrollpanel.lua:14

chudders1231 avatar Jul 31 '18 03:07 chudders1231

Can you please show the code you're using.

handsomematt avatar Jul 31 '18 07:07 handsomematt

The current code that i am using is on an entity with a 2D3D panel running from it: https://pastebin.com/qeJpzNgX

chudders1231 avatar Jul 31 '18 16:07 chudders1231

Now, there isn't an error at all but the combobox still opens up on my screen: http://i.prntscr.com/K6e-EmntQGCf-NkLBauyNQ.png

chudders1231 avatar Jul 31 '18 17:07 chudders1231

I can confirm that this is indeed the case. When DComboBoxes are clicked, the DComboBox will open up on the player's screen and any buttons clicked on the screen will cause the DComboBox to disappear like normal, but will not change the option on the 3D2D panel.

eggroll-bot avatar Dec 16 '19 07:12 eggroll-bot