Commit graph

297 commits

Author SHA1 Message Date
Rémi Verschelde
8f1915eb90
Revert "Fix selecting popup menu items on mouse release" 2024-02-20 10:05:41 +01:00
Rémi Verschelde
92951b0295
Merge pull request #86952 from ryevdokimov/fix-selecting-popup-menu-items-on-mouse-release
Fix selecting popup menu items on mouse release
2024-02-14 10:59:40 +01:00
kobewi
4f29ef82db Add PropertyListHelper to PopupMenu 2024-02-11 12:09:55 +01:00
A Thousand Ships
15369fdb1d
Remove unnecessary this-> expressions 2024-01-29 09:59:18 +01:00
mrcdk
c9bdccf7f2 Expose PopupMenu get_item_multistate(), get_item_multistate_max() and set_item_multistate_max() 2024-01-22 20:07:19 +01:00
bruvzg
5a61fecd0e
[macOS] Do not unbind PopupMenu from global menu on clear call. 2024-01-16 15:33:14 +02:00
Rémi Verschelde
c1da69d8f2
Merge pull request #86141 from Maran23/popup-hover-height-calc
Fix Popup hover and height calculation are off by some pixels
2024-01-15 13:23:42 +01:00
Robert Yevdokimov
06c2cda848 Fix selecting popup menu items on mouse release 2024-01-14 17:45:52 -05:00
Rémi Verschelde
365755fb34
Merge pull request #84946 from DarkMessiah/default-theme-checkbox-disabled-state
Use disabled icons for CheckBox in DefaultTheme
2024-01-10 12:03:12 +01:00
Rémi Verschelde
6c390b620d
Merge pull request #84445 from Rubonnek/add-const-references-clang-tidy
Add const references detected by clang-tidy
2024-01-04 14:25:33 +01:00
Rémi Verschelde
0c36bd791d
Merge pull request #82900 from bruvzg/macos_menu_global_shortcuts
[PopupMenu] Handle shortcuts with "global" flag directly.
2024-01-03 15:41:04 +01:00
bruvzg
15cdc52658
[PopupMenu] Handle physical_keycode and key_label of shortcuts. 2023-12-30 13:17:46 +02:00
Yuri Sizov
8a9aa30348 Merge pull request #81243 from Sauermann/fix-window-events
Fix internal events not being delivered to some Window types
2023-12-19 13:01:00 +01:00
Wilson E. Alvarez
a3cb1b096f
Add const references detected by clang-tidy 2023-12-16 13:36:44 -05:00
Marius Hanl
18fedd9c13 Fix Popup hover and height calculation are off by some pixels
This was caused by an incorrect calculation of the v_separation where it was not needed
2023-12-14 02:24:25 +01:00
bruvzg
0d44b50520
[macOS] Add default Window and Help menus, allow special menu customization. 2023-12-13 23:20:05 +02:00
Stanislav Labzyuk
ff59496632 Use disabled icons for CheckBox in DefaultTheme 2023-11-19 22:01:53 +01:00
Markus Sauermann
fa02d19fd1 Fix internal events not being delivered to some Window types
`AcceptDialog`, `Popup` and `PopupMenu` no longer subscribe to
"window_input" signal, because that is only sent if it is not an
internal signal.

Instead they receive events in `_input_from_window`. They ensure that
the event is also propagated to their super-function, just like
previously the signals would be treated.
2023-11-14 20:29:17 +01:00
Yuri Sizov
edcad2ea88 Allow auto-generated node names in PopupMenu::add_submenu_item 2023-11-09 17:12:41 +01:00
jsjtxietian
137b25cf53 Fix activate_item_by_event infinite recursion crash 2023-11-01 10:29:59 +08:00
A Thousand Ships
f721b34b4e Ensure input event is valid in PopupMenu::activate_item_by_event 2023-10-25 17:45:01 +02:00
Yuri Sizov
215e036600 Add bulk change guards to successive theme overrides in Editor and GUI 2023-10-19 18:14:14 +02:00
Yuri Sizov
ccb989569d Fix incorrect offset of PopupMenu separator icons 2023-10-17 20:38:35 +02:00
Rémi Verschelde
c1fed53943
Merge pull request #80271 from Ymanawat/optionmenu-scroll-test
Fix scrolling on keyboard/controller input
2023-10-09 15:30:57 +02:00
bruvzg
f93e254b58
[PopupMenu] Handle shortcuts with "global" flag directly. 2023-10-06 11:16:41 +03:00
bruvzg
d1aaa914f3
[macOS] Add about_to_open and popup_hide callback for the global menus, move part of logic to the PopupMenu to allow live menu modification. 2023-10-04 09:49:51 +03:00
kobewi
df24882f9a Free submenu children when clearing PopupMenu 2023-09-25 16:45:41 +02:00
PrecisionRender
76fad10978 Expose PopupMenu activate_item_by_event method 2023-09-15 10:27:49 -05:00
Yuri Sizov
fe000277ea Bind remaining theme properties to their respective classes
This adds binds for GraphEdit/GraphElement/GraphNode, which were
skipped before due to a rework. This also adds binds for Window,
which was skipped before due to a complicated code organization.

Also adds theme cache entries/direct cache access to a few places
that previously missed it. Some theme properties are now exposed
to other classes via friendships or public getters for convenience.

This removes all string-based theme access from scene/ classes.
2023-09-13 19:31:35 +02:00
Rémi Verschelde
013bbd1a1e
Merge pull request #81477 from timothyqiu/aligned
Fix submenu alignment with parent menu item
2023-09-11 15:38:54 +02:00
Yuri Sizov
2924bfd4d3 Register theme properties with ThemeDB 2023-09-11 13:45:23 +02:00
Haoyu Qiu
e5ad35a95f Fix submenu alignment with parent menu item 2023-09-09 14:32:21 +08:00
Yogendra Manawat
a16fdb05ae Fix scrolling popup_menu On keyboard/controller input 2023-08-30 23:31:22 +05:30
Tomasz Chabora
3dd881b4e4 Add option to allow echo events in menu shortcuts 2023-08-16 16:59:17 +02:00
kobewi
de4a3fa151 Unify and streamline connecting to Resource changes 2023-07-17 19:35:57 +02:00
bruvzg
4790da7900
[macOS] Implement optional native file selection dialog support for sandboxed apps. 2023-07-12 22:36:24 +03:00
Yuri Sizov
631d51c46c Merge pull request #78476 from Sauermann/fix-embedded-safe-area
Embedded Popups store their safe_rect in their embedder
2023-07-12 15:09:20 +02:00
Florian Kothmeier
c33748d954 Fix invalid minimum size for translated messages in option button 2023-06-29 15:01:36 +02:00
Markus Sauermann
a12627765f Embedded Popups store their safe_rect in their embedder
Storing it in the DisplayServer didn't make sense in this case,
because the embedded window is unknown to the DisplayServer.
2023-06-20 18:06:26 +02:00
Markus Sauermann
840e2b14f3 Remove unused variable PopupMenu::parent_rect
This private variable is not read anywhere.
Remove it and all places, where it is set.
2023-06-15 12:08:47 +02:00
Ninni Pipping
0c16082e1e Use get_node_or_null when null checks are present
Avoids duplicate or unnecessary errors
2023-06-10 13:22:56 +02:00
Rémi Verschelde
f00c971b81
Merge pull request #63168 from Levrault/master
Fix: InputEventJoypadMotion should trigger only once on a vslider
2023-06-05 18:04:39 +02:00
Luc-Frédéric Langis
166ca77f20 feat(gamepad): improve gamepad behavior with slider and popup_menu 2023-06-05 10:20:46 -04:00
Yuri Sizov
6a1d3198d1
Merge pull request #76854 from CapitaineCookie/fix-change-type
Fix crash when changing node type from PopupMenu to ItemList
2023-06-02 13:03:55 +02:00
Ninni Pipping
44a5b710f5 Unify item indexing in PopupMenu 2023-05-24 15:58:50 +02:00
Clement C
999a1fffec Fix crash when changing node type from PopMenu to ItemList 2023-05-12 23:29:52 +02:00
the-sink
a85eef4367 Add icon_modulate functionality to PopupMenu 2023-05-08 15:25:00 -07:00
Yuri Sizov
1522762dc9 Make icons of scripted and custom classes fit the editor UI
Also:
- Add an option to limit the icon size in PopupMenu.
This is similar to how this works in Tree and TreeItem.
- Add the same option to TabBar.
- Add a theme constant for Tree, PopupMenu, Button, and
TabBar to apply this limit on the control level.

Co-authored-by: Daylily-Zeleen <daylily-zeleen@foxmail.com>
2023-03-31 21:39:02 +02:00
bruvzg
cebfc02d6f
Revert "Reordering emitted signals in PopupMenu" and fix editor selection issue in the safer way. 2023-02-24 21:17:05 +02:00
Nong Van Tinh
5928d801a9 Reordering emitted signals in PopupMenu 2023-02-17 23:18:56 +07:00