Commit graph

165 commits

Author SHA1 Message Date
Daniel Ting 91f7af48eb
Fix opening URLS with special characters in macOS
The Online Tutorials section of InputMap in the editor's built-in
documentation viewer contains this link:

docs.godotengine.org/en/latest/tutorials/inputs/inputevent.html#inputmap

The macOS implementation for opening a link percent-encodes it before
sending it to the browser, resulting in a 404. This is to fix #13422
where filenames with special characters could not be opened in Finder.
However, this breaks URLS so I added a check to see if the resource
scheme is file:// and if so, only then is it escaped. This allows other
schemes like `http`, `ftp`, and `mailto` to be used.
2020-08-14 09:14:58 +03:00
bruvzg 31d84838ac
[macOS] Make move_window_to_foreground to take focus in addition to moving window to front. 2020-08-14 09:14:58 +03:00
bruvzg 0b118594f9
[macOS] Send resize event without actually resizing window on backing change.
Co-authored-by: Haoyu Qiu <timothyqiu32@gmail.com>
2020-08-14 09:14:57 +03:00
Rémi Verschelde b97401f304 Update copyright statements to 2020
And apply clang-format 10 to the codebase.
2020-08-13 22:58:13 +02:00
bruvzg 7894c6176c Replace IOHIDDeviceRegisterRemovalCallback with IOHIDManagerRegisterDeviceRemovalCallback to fix gamepad disconnection callback on macOS Catalina.
(cherry picked from commit 6b23e36dbc)
2020-05-28 14:09:22 +02:00
Ibrahn Sahir 9344851b05 Fixed hang when segfaulting after OS object destroyed (OSX and X11)
The two POSIX style crash handlers (OSX and X11) now remove their signal
handlers when they are destroyed.
Additonally if they are called while no OS singleton is set, they will
simply abort(). This should not happen now that they remove themselves,
but if a future change seperates OS object and crash handler lifetimes,
this may be easier to report/debug than hanging on SIGSEGV.
2020-02-22 08:44:16 -05:00
Xavier Sellier 400e273eee Fallback to the dummy audio driver if no other driver works
Fix this issue https://github.com/godotengine/godot/issues/1684
2019-12-19 10:16:01 -05:00
bruvzg 36eb43fff7 Fix non-HiDPI mode on HiDPI displays on macOS Catalina.
(cherry picked from commit 509afcea92)
2019-10-25 16:31:02 +02:00
Rémi Verschelde 7562ce053a Update copyright statements to 2019 2019-06-04 11:41:49 +02:00
Guilherme Felipe 72d4fd8f0d Fix Input::set_custom_mouse_cursor showing cursor when it's invisible 2018-09-17 12:24:44 -03:00
Rémi Verschelde bb13fa896e Style: Format code with clang-format 6.0.1 2018-07-18 17:56:12 +02:00
Guilherme Felipe dda8937ef3 Fix memory leak in set_custom_mouse_cursor 2018-05-26 15:55:57 -03:00
Guilherme Felipe 2f823eb6a7 Prevent crash for invalid reference 2018-05-08 15:13:32 +00:00
Rémi Verschelde 7cb027d071
Merge pull request #18362 from guilhermefelipecgs/support_for_atlas_tex_on_cursor
Add support for atlas texture on set_custom_mouse_cursor
2018-05-01 10:01:25 +02:00
Guilherme Felipe d65e95e5d6 Add support for atlas texture on set_custom_mouse_cursor 2018-04-24 18:19:10 -03:00
Guilherme Felipe 6217457b14 [2.1] Fix custom cursor when it's hidden
Port of #18075
2018-04-22 12:05:33 -03:00
Guilherme Felipe 0988796f3c Remove size restriction for mouse cursor 2018-04-05 15:35:20 -03:00
Rémi Verschelde 6a180a6983
Merge pull request #15565 from RandomShaper/adpod-topmost-2.1
Add new window setting: always-on-top (2.1)
2018-02-14 16:43:20 +01:00
Rémi Verschelde 4e46b0b668
Merge pull request #13930 from marcelofg55/center_window_2.1
Added OS::center_window to center the window precisely on desktop platforms
2018-02-14 00:15:07 +01:00
Pedro J. Estébanez f43981e9a6 Implement always-on-top for MacOS
Courtesy of @bruvzg.
2018-01-30 20:40:12 +01:00
Rhody Lugo 7b25a33762 add Colemak layout 2018-01-23 03:15:45 -04:00
Rémi Verschelde 3102dc17ee
Merge pull request #13437 from xsellier/bugfix/mouse-cursor-lag
Implement hardware cursor acceleration for Godot Engine 2.1
2018-01-03 08:36:44 +01:00
Rémi Verschelde 2712014744 Update copyright statements to 2018
Happy new year to the wonderful Godot community!
2018-01-02 11:27:24 +01:00
Xavier Sellier 377fdc1e33 Hardware cursor implementation for Godot Engine 2.1
- Remove all references to the variable 'custom_mouse_cursor_hotspot' and 'custom_mouse_cursor' from the project settings.
- Indeed, to implement a custom cursor we need to define a sprite for each 'state' of the cursor. Using those variables in the projects settings would define only the _main_ cursor.
- Cleanup the VirtualServer (Remove references to cursor_set_visible, cursor_set_texture and cursor_set_pos)
- Cleanup the Input (set_mouse_in_window should not be used anymore)
- Update the documentation
- Implement it for windows, X11, Javascript, BB 10, OSx, iOS, server, android
- NOT IMPLEMENTED FOR WINRT (As of today, I'm not able to implement this one, this post might help)
- NOT IMPLEMENTED FOR HAIKU (Support of this platform seems perfunctory)
- Build it for Windows, Android and OSX
2017-12-15 11:37:36 -05:00
Rémi Verschelde acb7107720 Style: apply clang-format (3.9.1) to current source 2017-12-11 15:18:06 +01:00
marcelofg55 129e0f34d0 Added OS::center_window to center the window precisely on desktop platforms 2017-12-03 17:13:26 -03:00
Rhody Lugo 714e02c0f6 disable caching for targets using helper functions 2017-11-28 16:14:24 -04:00
Rhody Lugo 388249c386 use the same cache for all branches for appveyor 2017-11-28 03:23:51 -04:00
Rhody Lugo 75925198be fix window position computations on macOS 2017-11-14 08:59:50 -04:00
Rhody Lugo f09bbfa372 change matrix and enable caching for Android, iOS and macOS (cross-compile) 2017-11-13 15:13:46 -04:00
Matthias Hoelzl fb236045de Make build scripts Scons 3.0/Python3 compatible
- Cherry picked #10662 and fixed merge conflicts.
- Manualy merged the change from #11904.
- Did not merge #12236 since I'm not sure whether the issue
  affects Godot 2.1 and I don't have VS2013 to test.
- Did not merge #11843 since it doesn't seem relevant (the
  code is only needed for creating DONORS.md, etc.).
- Did not merge #10727 and #11752 since they seem to be
  already included in #11742.
- The Windows and Linux builds have been tested with Scons 3.0
  using Python 3.
- OSX and iOS should hopefully work but are not tested since
  I don't have a Mac.
- Builds using SCons 2.5 and Python 2 should not be impacted.
2017-10-24 06:41:32 +02:00
Marcelo Fernandez 5cf2fc3a5f Implemented vsync OS functions for OS X 2017-10-23 12:05:42 -03:00
Marcelo Fernandez d706ee6f0a Ported BastiaanOlij code from master to export to .dmg on OS X, with some improvements 2017-09-21 17:47:50 -03:00
Marcelo Fernandez b0d5596738 Added OS::move_path_to_trash function, implemented only on OS X for now. 2017-09-21 17:45:32 -03:00
Marcelo Fernandez 60cf34b968 Added a crash handler to dump the backtrace on Windows, Linux and OS X 2017-09-19 19:56:24 -03:00
Rémi Verschelde 9d598833d2 Use HTTPS URL for Godot's website in the headers 2017-08-27 14:11:45 +02:00
Fabio Alessandrelli cc9d701658 Allow building fat binaries with osxcross
(cherry picked from commit d7f08ead4e)
2017-08-27 13:00:24 +02:00
Marcelo Fernandez e3394fc437 Fix y axis for set_window_position on OS X 2017-08-21 15:36:55 -03:00
Vasiliy Makarov d37d9aea8e fix build for osx 2017-08-19 10:47:15 +03:00
Marcelo Fernandez 647c4ae5bf Add closest_power_of_2 func and implement mix_rate/latency on OS X 2017-08-18 12:10:21 -03:00
Marcelo Fernandez fe37afa8df Implemented borderless window functions on OS X 2017-08-14 09:53:05 -03:00
bruvzg 8edc3991fd Duplicate error messages to macOS logging system
(cherry picked from commit 68bf243461)
2017-08-13 20:29:46 +02:00
bruvzg 5b76a456da Fix warp_mouse_pos on macOS 2017-08-05 00:00:05 +03:00
Rémi Verschelde c2fd0e65f7 Merge pull request #9986 from marcelofg55/2.1
Fix get_screen_* funcs returning old values after resolution changes on OS X
2017-07-31 14:03:15 +02:00
Rémi Verschelde c1f54e1a45 Style: Apply clang-format on all files
Thus fixing some invalid changes that had still made it to the 2.1 branch.
2017-07-30 23:00:25 +02:00
Marcelo Fernandez 6eedfe4ecb Fix get_screen_* funcs returning old values after resolution changes on OS X 2017-07-30 16:58:00 -03:00
bruvzg ad034962f1 Change display scale when moving the window from monitor to monitor
(cherry picked from commit d18922a56e)
2017-07-30 21:42:17 +02:00
Marcelo Fernandez a6129f0a21 Fix mutex initialisation in OS X Audio Driver 2017-07-28 16:17:46 -03:00
Rémi Verschelde 93e06fa1a8 Merge pull request #9812 from bruvzg/2.1
Add macOS main menu (2.1)
2017-07-28 11:05:22 +02:00
Rémi Verschelde 45566c61e3 Merge pull request #9836 from bruvzg/2.1-resize-fix
Improved macOS window resizing behaviour (2.1)
2017-07-28 11:02:21 +02:00