summaryrefslogtreecommitdiff
path: root/scene/gui/popup_menu.cpp
AgeCommit message (Collapse)Author
2020-04-02Merge pull request #37504 from qarmin/out_of_bound_cursorRémi Verschelde
Fix array out of bounds access caused by uninitialised variables
2020-04-01Fix out of bound array access caused by unassigned variableRafał Mikrut
2020-03-30fixed PopupMenus letterjumping on any InputEventLeleat
2020-03-26Popups have also been converted to windowsJuan Linietsky
Controls using the old modal API have been replaced to use popups.
2020-03-26Open sub-windows as embedded if the OS does not support themJuan Linietsky
2020-03-26Popups are now windows also (broken!)Juan Linietsky
2020-03-26Refactored input, goes all via windows now.Juan Linietsky
Also renamed Input to InputFilter because all it does is filter events.
2020-03-26Refactored Input, create DisplayServer and DisplayServerX11Juan Linietsky
2020-03-01Merge pull request #18020 from bruvzg/input_fix_non_latin_and_add_hw_scancodesRémi Verschelde
Fix non-latin layout scancodes on Linux, adds access to physical scancodes.
2020-02-28Signals: Manually port most of remaining connect_compat usesRémi Verschelde
It's tedious work... Some can't be ported as they depend on private or protected methods of different classes, which is not supported by callable_mp (even if it's a class inherited by the current one).
2020-02-28Signals: Port connect calls to use callable_mpRémi Verschelde
Remove now unnecessary bindings of signal callbacks in the public API. There might be some false positives that need rebinding if they were meant to be public. No regular expressions were harmed in the making of this commit. (Nah, just kidding.)
2020-02-25Variant: Added 64-bit packed arrays, renamed Variant::REAL to FLOAT.Juan Linietsky
- Renames PackedIntArray to PackedInt32Array. - Renames PackedFloatArray to PackedFloat32Array. - Adds PackedInt64Array and PackedFloat64Array. - Renames Variant::REAL to Variant::FLOAT for consistency. Packed arrays are for storing large amount of data and creating stuff like meshes, buffers. textures, etc. Forcing them to be 64 is a huge waste of memory. That said, many users requested the ability to have 64 bits packed arrays for their games, so this is just an optional added type. For Variant, the float datatype is always 64 bits, and exposed as `float`. We still have `real_t` which is the datatype that can change from 32 to 64 bits depending on a compile flag (not entirely working right now, but that's the idea). It affects math related datatypes and code only. Neither Variant nor PackedArray make use of real_t, which is only intended for math precision, so the term is removed from there to keep only float.
2020-02-25Rename `scancode` to `keycode`.bruvzg
Add `physical_keycode` (keyboard layout independent keycodes) to InputEventKey and InputMap. Fix non-latin keyboard layout keycodes on Linux/X11 (fallback to physical keycodes).
2020-02-20Reworked signal connection system, added support for Callable and Signal ↵Juan Linietsky
objects and made them default.
2020-02-11Texture refactorJuan Linietsky
-Texture renamed to Texture2D -TextureLayered as base now inherits 2Darray, cubemap and cubemap array -Removed all references to flags in textures (they will go in the shader) -Texture3D gone for now (will come back later done properly) -Create base rasterizer for RenderDevice, RasterizerRD
2020-01-03Clears button mask before activating menu itemHaoyu Qiu
2020-01-01Update copyright statements to 2020Rémi Verschelde
Happy new year to the wonderful Godot community! We're starting a new decade with a well-established, non-profit, free and open source game engine, and tons of further improvements in the pipeline from hundreds of contributors. Godot will keep getting better, and we're looking forward to all the games that the community will keep developing and releasing with it.
2019-12-13doc: Sync classref with current sourceRémi Verschelde
Also apply clang-format.
2019-12-10Fixes long popup menu scroll behaviorHaoyu Qiu
Popup menus longer than the viewport have stange behaviors before this fix: * They always have one pixel outside the viewport. * You can scroll down the long menu even if bottom outside screen and top inside the screen. (Only menus one pixel above the screen is limited to scroll down.)
2019-10-08PopupMenu: Fix missing text/xl_text when using add_shortcutRémi Verschelde
Use macros to ensure that `text`, `xl_text` and `id` are always set using the same logic. Fixes #25519. Also fixes up #26914 when `p_id == -1` handling was only added for a couple methods instead of all of them.
2019-10-08PopupMenu: Reorder add_* methods in more natural orderRémi Verschelde
Also adds `add_icon_radio_check_shortcut` matching `add_icon_radio_check_item`, binds them for scripting languages, and binds `add_multistate_item`.
2019-08-09Remove ERR_EXPLAIN from scene/* codeTomasz Chabora
2019-05-31Improvements to incremental searchTomasz Chabora
2019-05-09Change "ID" to lowercase "id"Aaron Franke
Reasoning: ID is not an acronym, it is simply short for identification, so it logically should not be capitalized. But even if it was an acronym, other acronyms in Godot are not capitalized, like p_rid, p_ip, and p_json.
2019-05-02Fix regression in 'PopupMenu' when icons have different values for width and ↵Michael Alexsander Silva Dias
height
2019-05-01Fix regression on 'PopupMenu's minimal sizeMichael Alexsander Silva Dias
2019-04-30Merge pull request #27204 from YeldhamDev/popupmenu_checkicon_offsetRémi Verschelde
Offset items in PopupMenu when Icons and Checks are present
2019-04-29Make buttons that trigger popups have the same scaleMichael Alexsander Silva Dias
2019-04-22Merge pull request #27673 from qarmin/small_fixesRémi Verschelde
Small fixes, mostly duplicated code
2019-04-08Small fixes, mostly dupicated codeqarmin
2019-03-18Offset items in PopupMenu when Icons and Checks are presentMichael Alexsander Silva Dias
2019-03-11Fixed optional idx argument in add_item (OptionMeny & PopupMenu)xDGameStudios
2019-02-20Add -Wshadow=local to warnings and fix reported issues.marxin
Fixes #25316.
2019-02-15Revert "Fix MenuButton item label disappearing when setting shortcut."Rémi Verschelde
2019-02-14Fix MenuButton item label disappearing when setting shortcut.Unknown
2019-01-01Update copyright statements to 2019Rémi Verschelde
Happy new year to the wonderful Godot community!
2018-12-15Fix item highlighting in PopupMenu for items with offsetMichael Alexsander Silva Dias
2018-11-11Fixed various uninitialised member variables in editor plugins.Ibrahn Sahir
2018-11-08-Moved EditorDefaultValue to ClassDB, made it coreJuan Linietsky
-Removed one and zero hints for properties, replaced by default value
2018-11-01Merge pull request #21962 from YeldhamDev/switch_hover_submenuJuan Linietsky
Fix MenuButton hover switching not happening with submenus open
2018-09-12Make core/ includes absolute, remove subfolders from include pathRémi Verschelde
This allows more consistency in the manner we include core headers, where previously there would be a mix of absolute, relative and include path-dependent includes.
2018-09-11Fix MenuButton hover switching not happening with submenus openMichael Alexsander Silva Dias
2018-08-17Merge pull request #21091 from hpvb/fix-removing-popup-menu-itemRémi Verschelde
Call minimum_size_changed() in PopupMenu::remove_item()
2018-08-16Call minimum_size_changed() in PopupMenu::remove_item()Hein-Pieter van Braam
When removing an item from a PopupMenu we need to update the control's size cache otherwise the size of the PopupMenu itself lags behind by 1 item size. Meaning the PopupMenu will remain too large.
2018-08-16Delay emitting pressed signals in PopupMenuHein-Pieter van Braam
When processing items we may actually delete the item we're processing in the callback for the signal. To avoid this, call the signal after we're done processing the items. But before hiding the popupmenu itself. Thanks to @reduz for writing the whole solution. This fixes #19842
2018-08-16PopupMenu item_pressed is sent before checking hide flags.Ovnuniarchos
2018-08-13Emit pressed events after processing itemsHein-Pieter van Braam
When processing items we may actually delete the item we're processing in the callback for the signal. To avoid this, call the signal after we're done processing the items. This fixes #19842
2018-07-29Merge pull request #15269 from ianb96/context_menu_improvementsJuan Linietsky
Context Menu Improvements
2018-07-26context menu improvementsIan
2018-07-26Reduce unnecessary COW on Vector by make writing explicitHein-Pieter van Braam
This commit makes operator[] on Vector const and adds a write proxy to it. From now on writes to Vectors need to happen through the .write proxy. So for instance: Vector<int> vec; vec.push_back(10); std::cout << vec[0] << std::endl; vec.write[0] = 20; Failing to use the .write proxy will cause a compilation error. In addition COWable datatypes can now embed a CowData pointer to their data. This means that String, CharString, and VMap no longer use or derive from Vector. _ALWAYS_INLINE_ and _FORCE_INLINE_ are now equivalent for debug and non-debug builds. This is a lot faster for Vector in the editor and while running tests. The reason why this difference used to exist is because force-inlined methods used to give a bad debugging experience. After extensive testing with modern compilers this is no longer the case.