summaryrefslogtreecommitdiff
path: root/scene/main/viewport.cpp
AgeCommit message (Collapse)Author
2023-02-01Merge pull request #66906 from Sauermann/fix-prohibit-inconsistent-size-stateRémi Verschelde
Prohibit inconsistent size state for SubViewport
2023-01-31Prohibit inconsistent size state for SubViewportMarkus Sauermann
Prohibit size changes of SubViewports with parent SubViewportContainers that have stretch mode enabled.
2023-01-31Merge pull request #65698 from KoBeWi/cameramanRémi Verschelde
Rework how current Camera2D is determined
2023-01-31Merge pull request #59310 from Sauermann/proposal-event-transformRémi Verschelde
Calculate window input event transform only on window change
2023-01-26Added assertion checkMarkus Sauermann
2023-01-26Merge pull request #68007 from Sauermann/fix-3d-captureRémi Verschelde
Fix event-content and mouse-signals with 3D-capture-on-drag
2023-01-26Merge pull request #68627 from Sauermann/fix-tooltip-positionRémi Verschelde
Fix position of Tooltips
2023-01-26Include the Window-transform into Viewport::get_final_transformMarkus Sauermann
2023-01-26Fix position of TooltipsMarkus Sauermann
CanvasItem::get_screen_transform returns a transform from the CanvasItem to the coordinate system, where a Popup - created as a child of the CanvasItem - should be opened. get_screen_transform makes some simplifications, that work well, when used in the editor, but not in general cases. Since Popups like Tooltips are now used more commonly in projects, it becomes necessary to correct these simplifications. This solution introduces Viewport::get_popup_base_transform, which makes the necessary calculations.
2023-01-20Merge pull request #71692 from HalcyonGarside/viewport-debug-draw-fixRémi Verschelde
Fix incorrect Viewport Debug Draw effects
2023-01-19Add 'Lighting' to list of Debug Draw viewport optionsHalcyonGarside
2023-01-17Fix crash on touch releaseMai Lavelle
2023-01-16Merge pull request #69598 from Sauermann/fix-focus-inverseRémi Verschelde
Calculate the mouse focus inverse transform only when needed
2023-01-16Add `WINDOW_FLAG_MOUSE_PASSTHROUGH` flag and enabled it for tooltips. Expose ↵bruvzg
`window_set_mouse_passthrough` to `Window`.
2023-01-09Calculate the mouse focus inverse transform only when neededMarkus Sauermann
Revival of #49158 Co-authored-by: Marcel Admiraal <madmiraal@users.noreply.github.com>
2023-01-08Use BitField<> in core type masksJuan Linietsky
* All core types masks are now correctly marked as bitfields. * The enum hacks in MouseButtonMask and many other types are gone. This ensures that binders to other languages non C++ can actually implement type safe bitmasks. * Most bitmask operations replaced by functions in BitField<> * Key is still a problem because its enum and mask at the same time. While it kind of works in C++, this most likely can't be implemented safely in other languages and will have to be changed at some point. Mostly left as-is. * Documentation and API dump updated to reflect bitfields in core types.
2023-01-07Add support for the custom initial screen for the main window, fix primary ↵bruvzg
screen detection.
2023-01-06Merge pull request #68429 from KoBeWi/PropertySettingsRémi Verschelde
Add PropertyInfo overload for GLOBAL_DEF
2023-01-05One Copyright Update to rule them allRémi Verschelde
As many open source projects have started doing it, we're removing the current year from the copyright notice, so that we don't need to bump it every year. It seems like only the first year of publication is technically relevant for copyright notices, and even that seems to be something that many companies stopped listing altogether (in a version controlled codebase, the commits are a much better source of date of publication than a hardcoded copyright statement). We also now list Godot Engine contributors first as we're collectively the current maintainers of the project, and we clarify that the "exclusive" copyright of the co-founders covers the timespan before opensourcing (their further contributions are included as part of Godot Engine contributors). Also fixed "cf." Frenchism - it's meant as "refer to / see".
2022-12-29Add safety-checks before some servers `free()`Adam Scott
2022-12-19Merge pull request #59682 from Sauermann/fix-following-viewport-transformRémi Verschelde
Include the follow-viewport-transform into CanvasLayer transform calculations
2022-12-18Include the following-viewport-transform into CanvasLayer transformsMarkus Sauermann
The following-viewport-transform was missing from several calculations
2022-12-11Add PropertyInfo overload for GLOBAL_DEFkobewi
2022-12-02Rework how current Camera2D is determinedkobewi
2022-11-30Fix routing of InputEventScreenDrag events to Control nodesFredia Huya-Kouadio
2022-11-28Merge pull request #59801 from Sauermann/fix-node2d-viewport-root-orderRémi Verschelde
Fix Viewport root order after Node2D raise
2022-11-25Merge pull request #68447 from Grimmr/clean-tooltips-on-WM-focus-offRémi Verschelde
Viewport cancels existing tooltip when window looses focus
2022-11-25Viewport cancels existing tooltip when window looses focusgrimmr
fixes #68197 when NOTIFICATION_WM_WINDOW_FOCUS_OUT is recieved by a viewport it will now call _gui_cancel_tooltip() to avoid it hanging around after the mouse events stop coming in
2022-11-22Fix CanvasTransform on RenderingServer when Viewport enters TreeMarkus Sauermann
Previously the Viewport didn't initialize its canvas transform in the RenderingServer.
2022-11-18Fixed _get_drag_data getting incorrect position on scaled controlsUxeron
2022-11-14Remove redundant Variant-types initializationsMarkus Sauermann
2022-11-14Merge pull request #68272 from Sauermann/fix-windowfocus-on-resizeRémi Verschelde
Fix Windowfocus on resizing
2022-11-14Drop physics mouseover as soon as the mouse moves over a ControlMarkus Sauermann
2022-11-11Merge pull request #68418 from Sauermann/fix-escape-dndRémi Verschelde
Allow canceling Drag and Drop with the Escape-Key
2022-11-08Allow canceling Drag and Drop with the Escape-KeyMarkus Sauermann
This patch implements the functionality to cancel Drag and Drop by using the escape key or more general, the ui_cancel action. Since this would be the third location, where the finalization of Drag and Drop would have to be implemented, that functionality was put into the private function _perform_drop. Simplified gui.drag_data.get_type() != Variant::NIL to gui.dragging because they are equivalent.
2022-11-07Fix SubViewport with default size being pinkMarkus Sauermann
A SubViewport with default-size doesn't display its content, but shows pink color, until it is resized. This patch makes sure, that the size gets set during initialization.
2022-11-04Fix Windowfocus on resizingMarkus Sauermann
When resizing a non-focused window, the previously focused Window got resized. This patch grabs focus for the actually resized window, before starting with the resizing.
2022-11-02Fixup Clang -Wtype-limits warnings introduced by #52350Rémi Verschelde
2022-11-02Fix Viewport root order after Node2D raiseMarkus Sauermann
2022-11-02Merge pull request #52350 from BimDav/viewport_canvas_cullRémi Verschelde
Added Viewport canvas cull mask feature
2022-10-31Viewport canvas cull mask featureBimDav
Co-authored-by: Valentin Zagura <puthre@gmail.com>
2022-10-31Merge pull request #67578 from KoBeWi/GEDITORRémi Verschelde
Unify usage of GLOBAL/EDITOR_GET
2022-10-31Merge pull request #67046 from Cykyrios/fix-invalid-tooltip-positionRémi Verschelde
Fix invalid tooltip position
2022-10-31Merge pull request #67445 from Zylann/rename_queue_deleteRémi Verschelde
Rename queue_delete => queue_free
2022-10-29Fix event-content and mouse-signals with 3D-capture-on-dragMarkus Sauermann
Fix for 3D-physics processing: - with enabled input_capture_on_drag now report correct position and normals in _input_event - mouse_enter and mouse_exit signals are emitted when the mouse cursor leaves the visible area of the 3D-object, independently of pressed mouse button or input_capture_on_drag - make sure that collision input events are sent in the right order with respect to mouse_enter and mouse_exit signals
2022-10-27Merge pull request #64710 from MinusKube/window-size-crashClay John
Prevent windows from having a size greater than device limit
2022-10-24Rename queue_delete => queue_freeMarc Gilleron
# Conflicts: # editor/plugins/tiles/tiles_editor_plugin.cpp
2022-10-24Remove unnecessary castsMarkus Sauermann
button_add_item and button_add are both Button p_parent is a Node3D CanvasItem can never be cast to Viewport
2022-10-18Unify usage of GLOBAL/EDITOR_GETkobewi
2022-10-15Expose Viewport::get_screen_transform to GDScriptMarkus Sauermann