Commit graph

132 commits

Author SHA1 Message Date
Megamouse
4c70864588 Add rsx capture shortcut 2020-09-16 21:57:55 +02:00
Megamouse
a845a0395a Input/Qt: Properly reset mouse hide timer 2020-09-09 00:22:48 +02:00
Megamouse
006f546e7c Fix idle timer 2020-09-02 14:22:00 +02:00
Megamouse
1dac01498c Update mouse lock logic
- fix headers
- update cursor whenever the mouse is moved
- unify cursor logic
- move m_mouse_hide_and_lock logic to handle_cursor (toggle_fullscreen is the trigger, not the handler)
- disable mouse lock and idle timer if the window is inactive
2020-09-02 14:22:00 +02:00
Bevan Weiss
ae0e454fc2 Use dynamic_cast to convert QWindow m_target to gs_frame
Used to access get_mouse_lock_state rather than going through the QWindow property tables.

Modify mouse hide and lock to default OFF when entering Windowed mode, and to default ON when entering Fullscreen unless 'show cursor in fullscreen' is configured
2020-09-02 14:22:00 +02:00
Bevan Weiss
ca3ee019cc GUI: Mouse Hide and Lock Keyboard Shortcut
This should address the second point of #4502.

A few notes:
1. it changes the current behaviour of the 'Fullscreen cursor'.  Currently it defaults to be captive.  This changes it so that it defaults to NOT being captive, but can be made captive with the CTRL+L key combination.
2. There are situations when in windowed mode it's possible to escape the captivity (it's like a minigame if you will).  This requires the mouse movement to exceed the bounds of the window in a single event scan.  It will just show up as a temporary visibility of the cursor when outside of the window bounds.  It's not too difficult to 'fix', but might not be a likely enough scenario to warrant either.
3. There currently isn't an ability to change what this keyboard combo maps to, but it's inline with a collection of other similar keyboard mappings.  I think adding such a more generic keyboard mapping system (not for just keypad items, but system items.. e.g. so that Emulator stop could be mapped to something other than CTRL+S etc) is a bit out-of-scope of this particular PR.
2020-09-02 14:22:00 +02:00
Bevan Weiss
9a51f22265 Remove call to start m_mousehide_timer in gs_frame constructor 2020-08-29 16:14:11 +02:00
Bevan Weiss
144b185802 Woops... premature commit/push.
Fixed up the usage of connect
2020-08-29 16:14:11 +02:00
Bevan Weiss
3c0f6a2919 Used new Qt connect syntax
Fixed indenting
Renamed click callback argument from 'val'->'checked'
Converted m_gui re-usage to just reference ui
Removed implicit capture from spinbox lambda
Corrected millisecond acronym from mS->ms
Removed superfluous QTimer include in gs_frame.cpp
2020-08-29 16:14:11 +02:00
Bevan Weiss
22c33d4fb4 Added settings and logic for auto-hide of mouse cursor.
In line with the Show Cursor in Fullscreen settings, these settings are only updated when the render window is first launched, and not during the game.
This could be revised (along with the Fullscreen Cursor) if it's more desired.
2020-08-29 16:14:11 +02:00
kd-11
fd2607ad52 rsx: Fix XBGR vs XRGB screenshots 2020-08-12 20:19:19 +03:00
Megamouse
c495ef10b0 Qt: fix random QWinTaskbarProgress crashes 2020-07-02 20:22:58 +02:00
Megamouse
b5f01372ee Windows: distinguish left and right modifiers
This is just some workaround until we either use a different input api for keyboards or until we refactor the keyboard_pad_handler to use Qt with native scan codes
2020-07-02 12:55:27 +02:00
Megamouse
bec6bde919 Qt/Input: update keyboard_pad_handler shortcuts
This is just some patchwork before the shortcuts get refactored eventually
2020-07-02 12:55:27 +02:00
Megamouse
eb5ec211c2 Input: remember registered ldd controllers
- Don't reset ldd pads when saving a pad config
- Prevent configuration of registered ldd pads in the gui while ingame
2020-05-13 11:17:58 +02:00
Pavel
9a4c26dc8c Qt: Option to disable keyboard hotkeys 2020-05-04 01:10:44 +03:00
Megamouse
2b69a68ef6 Qt: show mouse in fullscreen 2020-05-02 09:27:54 +02:00
Megamouse
f27de28ee9 Qt: add open file location to screenshot preview
Remove duplicate slash from screenshot path
2020-03-25 11:50:06 +01:00
Megamouse
f7666f44da Untangle GUI and input includes 2020-02-24 16:31:01 +01:00
Megamouse
ee54ba970a GUI: add custom title format to settings dialog 2020-02-15 20:33:02 +01:00
Nekotekina
0d7aa5e310 GUI: implement custom title format
New option "Window Title Format" in Misc.
Backward compatible with FPS disabler.
Make rpcs3:::get_branch() return string_view.
2020-02-13 21:24:52 +03:00
Nekotekina
4bc431ec31 Silence deprecation warning (implicit capture of this on [=]) 2020-02-10 14:47:12 +03:00
Megamouse
901fc87bca Only start the playtime clock if it makes sense 2020-02-08 07:13:29 +01:00
Nekotekina
d9a0619ddd Remove legacy GENERAL log channel
Add some more log channels instead.
2020-02-01 07:49:38 +03:00
Silent
9f678cc47a Fix code relying on initialization order
Allows Debug - LLVM to boot
2020-01-31 11:23:55 +03:00
Eladash
48a847d1b6 Qt: Bugfixes regarding usage of ShowConfirmationBox 2020-01-30 21:49:08 +01:00
Emmanuel Gil Peyrot
e30173a835 rsx: Make X11 optional on Linux
This makes it possible to build rpcs3 on a pure Wayland system, without
the Xlib installed.
2019-12-20 10:48:03 +00:00
Zangetsu38
af8ebc76e2 Modules/cellGem: Implement pos, quat and handle_pos in Gemstate for mouse.
Modules/cellGem: Fix name for gem_image_state.
Modules/cellGem: Implement projectiion(x/y) in gem_image_State for mouse.
Modules/cellGem: Add cross, triangle, circle and start with use middle click for mouse.
Modules/cellGem: Refactor global code.
Modules/cellGem: fix some warning with initializing value.
2019-12-10 23:20:13 +01:00
Nekotekina
835892aa51 C-style cast cleanup VII 2019-12-05 02:10:15 +03:00
Megamouse
0bad56da67 cellScreenshot: initial implementation 2019-10-17 21:24:25 +02:00
Markus Stockhausen
2850d0c6bc avoid update of window title
only update title if user really wants to display the FPS during gameplay.
2019-10-17 21:15:14 +02:00
Megamouse
19e0d099b6 config: dynamically show_fps_in_title 2019-09-29 21:00:17 +02:00
RipleyTom
87bf0386c4 Screenshot function 2019-08-14 19:24:42 +02:00
Megamouse
b44b44b3c4 Qt: cleanup some comments 2019-07-25 08:53:07 +02:00
kd-11
d361eedbec rsx: Clean up window management code
- Removes a lot of wm_event code that was used to perform window management and is no longer needed.
- Significantly simplifies the vulkan code.
- Implements resource management when vulkan window is minimized to allow resources to be freed.
2019-06-10 14:57:03 +03:00
scribam
bf557ea6e6 Use the more efficient character literal overload for find_first_of/find_last_of
Recommendation from Clang-Tidy: https://clang.llvm.org/extra/clang-tidy/checks/performance-faster-string-find.html
2019-06-01 22:59:23 +03:00
Megamouse
bb0609372d Qt: go out of fullsceen if exit game pop up is triggered 2019-04-24 21:48:36 +02:00
kd-11
3bfa564ef8 vk/windows: Try to keep msq thread from ever stopping
- NVIDIA drivers hook into the msq before our nativeEvent handler. This means NV is aware of events before rpcs3 is aware of them and sometimes stops until a new event is triggered.
  If rpcs3 is inside a driver call at this time, the system will deadlock since the driver waits for msq which waits for the renderer which waits for the driver.
- Use explicit hook management to control window events
- Add fence timeout to attempt detection of surface loss events
2019-01-31 21:53:02 +03:00
Megamouse
5f9b441dd7 Qt: spawn Confirmation Dialog on exit 2019-01-05 01:50:42 +01:00
Megamouse
e80574cbd2 RSX/Qt: set min gs_frame size to 160x90 to prevent stupid new Vulkan bug 2018-12-22 23:10:34 +01:00
Megamouse
79003cd089 Qt/windows: use Qt's high dpi scaling 2018-12-22 23:10:34 +01:00
RipleyTom
7f3eaed435 Fullscreen fix 2018-12-03 14:16:47 +03:00
RipleyTom
25414953e0 Fixes maximize window to properly update the render surface in Vulkan 2018-12-01 22:20:59 +03:00
kd-11
f505ac7b63 qt/gs_frame: Hotfix
- Dynamically check the loaded QT library version in case of mismatch
- Fixes using 5.11.1 builds with non-buggy libraries and vice versa
2018-11-22 10:21:13 +03:00
Zion Nimchuk
db40cbda58 Qt: set Vulkan surface in gs_frame 2018-10-20 18:49:04 +02:00
Nekotekina
ca5158a03e Cleanup semaphore<> (sema.h) and mutex.h (shared_mutex)
Remove semaphore_lock and writer_lock classes, replace with std::lock_guard
Change semaphore<> interface to Lockable (+ exotic try_unlock method)
2018-09-03 23:00:36 +03:00
Dzmitry Malyshau
c452b43ebc Basic support for Vulkan Portability on OSX 2018-08-28 21:20:11 +03:00
Megamouse
de693b0da1 Qt: handle upstream trolling 2018-07-15 20:29:14 +04:00
Megamouse
0ffaf6c1ce Qt/RSX: reset gs_frame taskbar progr. when closing native progr. dialogs
I forgot that the gs_frame's taskbar progress will stay unchanged due to its persistence, unlike the msgdialog.
2018-06-19 21:58:09 +03:00
Megamouse
2b8cab906c Qt: clamp progress bar values 2018-06-11 22:41:38 +03:00