Commit Graph

181 Commits

Author SHA1 Message Date
ben hoffman
8006b9defb Add a "Primary Platform User" virtual function to allow platforms to define a primary user for things like the keyboard and mouse which there will only be one of. Map the Default Input device to the Primary Platform user upon construction of the device mapper. This gaurantees that there will be a platform user registered for the SlateApplication upon start up.
Add a callback to OnUserLoginChangedEvent to the device mapper. This will provide platforms a hook for when a platform user is logged in or out and allow you to remap any previously paired input devices away from the now logged out user.

#jira UE-147792
#rb david.harvey
#preflight 628d2d25347b7778b6ceb043

[CL 20363459 by ben hoffman in ue5-main branch]
2022-05-25 09:27:37 -04:00
Devin Doucette
3045e3c75f Logging: Changed CanBeUsedOnPanicThread() to return false by default
The previous default of CanBeUsedOnAnyThread() proved unsafe since some output devices can safely be used on any thread but cannot safely be used during a crash. CanBeUsedOnAnyThread() was used pre-5.1 to control serialization to an output device during a crash, but optimizations in 5.1 have uncovered that some of these were never safe.

#preflight 62856506614041edb7a6de4b
#rb Zousar.Shaker
#rnx

[CL 20280354 by Devin Doucette in ue5-main branch]
2022-05-19 10:39:18 -04:00
David Harvey
9cc4146fbc move HoloLens runtime source to platform extension folder.
#jira UE-149794
#rnx
#rb Jeff.Fisher
#preflight 6284cd49614041edb76395dc

[CL 20258963 by David Harvey in ue5-main branch]
2022-05-18 06:59:59 -04:00
Andrew Davidson
9741042a2b Reduce use of UE_DECLARE_LWC_TYPE macro to improve Intellisense.
Moved Math forward declarations from CoreFwd.h to Math/MathFwd.h
#rb steve.robb
#preflight 62837df43c1cdc59e2b07dd5

[CL 20240602 by Andrew Davidson in ue5-main branch]
2022-05-17 07:05:35 -04:00
mathieu dunlay
d1c9bd0b41 Adding FirstMove events to windows, enabled with "WindowsApplication.EnableFirstTouchEvent"
#ROBOMERGE-AUTHOR: mathieu.dunlay
#ROBOMERGE-SOURCE: CL 20163603 via CL 20164288 via CL 20164397 via CL 20164495 via CL 20164557
#ROBOMERGE-BOT: UE5 (Release-Engine-Staging -> Main) (v943-19904690)

[CL 20165691 by mathieu dunlay in ue5-main branch]
2022-05-12 12:13:54 -04:00
Chris Babcock
3cba90fb40 Add r.Mobile.DesiredResX/Y for Android and -mobileresx and -mobileresy commandline overrides
#jira UE-144742
#android
#review @Jack.Porter
#rb Jack.Porter

#preflight https://horde.devtools.epicgames.com/job/6272ceb83e1f2a9d3a903d7a

[CL 20046802 by Chris Babcock in ue5-main branch]
2022-05-04 15:15:55 -04:00
ben hoffman
2c3741269c Update comment in the GenericPlatformInputDeviceMapper to keep the BP lib up to date
#jira UE-147801
#rb trivial
#preflight skip
#rnx

[CL 20008057 by ben hoffman in ue5-main branch]
2022-05-02 10:10:10 -04:00
ben hoffman
cee9ba5038 Remove the UE::Input namespace because the types won't be able to be BP exposed if we use namespaces. This is because UHT does not support any namespacing outside of "::Type" for some enums, which wouldn't work for the Device State struct. This renames the FInputDeviceState struct to FPlatformInputDeviceState because without the namespaces it conflicts with an existing slate type now that it outside the namespace.
Move the FPlatformInputDeviceState and EInputDeviceConnectionState declarations to the CoreMiscDefines file so that they can be correctly exported in the NoExports.h file. We need them to be in a different file than the base GenericPlatformInputDeviceMapper.h because we need to keep the APPLICATIONCORE_API on that class, which is not available in the NoExports.h file.

#jira UE-147801
#rb trivial
#rnx
#preflight 62632b02d4489684ed592c34

[CL 19902249 by ben hoffman in ue5-main branch]
2022-04-25 10:27:16 -04:00
james doverspike
58c7d94999 Add support to default RHI based on device id and a list of devices that are capable of updating to avoid prompting users who can't update their drivers
#p4v-cherrypick 19897004

#ROBOMERGE-AUTHOR: james.doverspike
#ROBOMERGE-SOURCE: CL 19896998 via CL 19897000 via CL 19897003 via CL 19897308 via CL 19897311
#ROBOMERGE-BOT: UE5 (Release-Engine-Staging -> Main) (v940-19807014)

[CL 19897438 by james doverspike in ue5-main branch]
2022-04-24 14:14:43 -04:00
ben hoffman
5e6e396663 Create the Platform Input Device Mapper. This provides an interface that platforms can use to create a map of Input Devices to their owning PlatformUser. This will allow for granular control of how many input devices are mapped to a single user, which some platforms want to do differently than others. The API can be used to query what devices are mapped to which user, so that you can easily determine which controller should recieve a force feedback event, or which user has pushed a certain button.
- Create the FInputDeviceID struct, which represents a single input device such as a gamepad, keyboard, or mouse. These are globally unique, and allocated by the Platform Input Device Mapper. This struct will replace the old "int32 ControllerID" that is used in various places to provide some type safety and maintainability.

- Functions to query all the currently connected devices on a given platform, as well as get their current state and owning platform users. These can be exposed to blueprints via the local player, game instance, or even a subsystem in the future. See UE-147801 for progress on Blueprint Support.

- New delegates for the ConnectionChange and PairingChange of a gamepad device that utilize the new FInputDeviceId and FPlatformUserId

- Add functions to the GenericApplicationMessageHandler for the "OnController_X" functions. These will be implemented later when I can replace the old uses of the "int32 ControllerId". See UE-147796.


#jira UE-147798
#rb David.Harvey
#preflight 62617c186971732e1318d0ec

[CL 19851010 by ben hoffman in ue5-main branch]
2022-04-21 12:25:34 -04:00
robert seiver
ceb65d0775 Removed an unused bool related to Gamepads
#jira none
#rb Brandon.Schaefer
#preflight none

[CL 19786956 by robert seiver in ue5-main branch]
2022-04-18 12:17:31 -04:00
robert seiver
c68adb3c60 Added support for IsGamepadAttached on Linux
#jira UE-33266
#rb Brandon.Schaefer
#fyi @Brandon.Schaefer
#preflight 625d8814d4124345879dcf9f

[CL 19786909 by robert seiver in ue5-main branch]
2022-04-18 12:12:28 -04:00
john barrett
976ee0fb42 CIS fix.
#rb none

#ROBOMERGE-AUTHOR: john.barrett
#ROBOMERGE-SOURCE: CL 19573269 via CL 19573278 via CL 19573287 via CL 19573292
#ROBOMERGE-BOT: UE5 (Release-Engine-Staging -> Main) (v938-19570697)

[CL 19575899 by john barrett in ue5-main branch]
2022-03-31 14:28:38 -04:00
robomerge
fd791b9484 Added log highlighting, based on log category and log search string.
Commandline usage:
-LogHighlights="LogNet Cyan, LogTemp Green"
-LogStringHighlights="UNetConnection::Close=Purple, NotifyAcceptingConnection accepted from=DarkGreen"

#rb Devin.Doucette

#ROBOMERGE-AUTHOR: john.barrett
#ROBOMERGE-SOURCE: CL 19572963 via CL 19572976 via CL 19572982 via CL 19572989
#ROBOMERGE-BOT: UE5 (Release-Engine-Staging -> Main) (v938-19570697)

[CL 19575887 by robomerge in ue5-main branch]
2022-03-31 14:28:15 -04:00
axel riffard
10f7d75ff4 Siri Remote touch panel is a dpad and add Virtual Keyboard support to tvOS
#rb.jack.porter
#jira UE-93988
#preflight 624576fcf4217035fa87b5c5

[CL 19570813 by axel riffard in ue5-main branch]
2022-03-31 05:55:09 -04:00
Michael Sartain
4d2efde0f4 Make FLinuxConsoleOutputDevice::Serialize Thread Safe
Set CanBeUsedOnAnyThread() to true and move to single printf in Serialize

#rnx
#jira UE-147459
#review-19549147 @Brandon.Schaefer, @Robert.Seiver
#preflight none

[CL 19549852 by Michael Sartain in ue5-main branch]
2022-03-29 17:19:42 -04:00
adam kinge
b22405acec Fix r.MobileContentScaleFactor being ignored and always defaulting to 1 on iOS
#jira UE-144079
#rb Jack.Porter
#preflight None

#ROBOMERGE-AUTHOR: adam.kinge
#ROBOMERGE-SOURCE: CL 19260968 in //UE5/Release-5.0/... via CL 19261966
#ROBOMERGE-BOT: UE5 (Release-Engine-Staging -> Main) (v924-19243027)

[CL 19269187 by adam kinge in ue5-main branch]
2022-03-04 13:05:08 -05:00
dave hunter
7dde981dc2 Fix window activation when menus close
CocoaWindows now store their Type.  This is used so that we can make sure that we can call OnWindowActivationChanged
when the menu closes.  This is needed to restore focus in the main window after the menu is triggered.  Several other
utility windows are now not treated as main windows.


[REVIEW] will.damon
#jira UE-139065
#rnx
#preflight n/a
#lockdown cristina.riveron


#ROBOMERGE-AUTHOR: dave.hunter
#ROBOMERGE-SOURCE: CL 19093114 via CL 19093772 via CL 19094565 via CL 19096071 via CL 19105329
#ROBOMERGE-BOT: UE5 (Release-Engine-Staging -> Main) (v921-19075845)

[CL 19146632 by dave hunter in ue5-main branch]
2022-02-25 09:42:22 -05:00
Brandon Schaefer
7d0478a607 Avoid double output when running with -stdout enabled
This does use LaunchEngineLoops output over Linux which means with -stdout no color coded warning/error messages

#jira none
#rb Michael.Sartain, Rober.Seiver
#preflight none

[CL 19074484 by Brandon Schaefer in ue5-main branch]
2022-02-22 12:01:59 -05:00
axel riffard
18439c9e89 Remove iOS13 and Metal 2.2 , implement iOS14 and Metal 2.4
#jira UE-140926
#rb jack.porter
[FYI] will.damon, carl.lloyd, richard.wallis, laura.hermanns
#lockdown rolando.caloca
#preflight 61fb957ec431b6aac0556693

#ROBOMERGE-OWNER: axel.riffard
#ROBOMERGE-AUTHOR: axel.riffard
#ROBOMERGE-SOURCE: CL 18841574 in //UE5/Release-5.0/... via CL 18841862 via CL 18841959
#ROBOMERGE-BOT: UE5 (Release-Engine-Test -> Main) (v910-18824042)
#ROBOMERGE-CONFLICT from-shelf

[CL 18842337 by axel riffard in ue5-main branch]
2022-02-03 09:10:01 -05:00
Michael Sartain
bcfb02e2d4 Fix UnrealLightmass spewing UE_LOGs to console for Linux
Add bIsWindowShown option to Linux Console Output Device
Default to true to match old behavior.
Add -nostdout by default in UnrealLightmass

#rb Brandon.Schaefer
#jira none
#preflight trivial

[CL 18817282 by Michael Sartain in ue5-main branch]
2022-02-01 18:14:33 -05:00
dave hunter
8f30b73b1d Menus are not main windows (Mac)
I've added a boolean AllowMainWindow to CocoaWindow which is now set to true unless the window is a menu.  This status is reported to the OS via the canBecomeMainWindow method.  It is also used by the MacApplication which will now not activate a window when a window that's being closed is not a main window (via AllowMainWindow).

#rb will.damon
#jira UE-137460
#preflight n/a

#ROBOMERGE-AUTHOR: dave.hunter
#ROBOMERGE-SOURCE: CL 18734334 in //UE5/Release-5.0/... via CL 18734343 via CL 18734356
#ROBOMERGE-BOT: UE5 (Release-Engine-Test -> Main) (v903-18687472)

[CL 18734361 by dave hunter in ue5-main branch]
2022-01-26 07:59:53 -05:00
marc audy
6553e6cd0a Remove as much C++ deprecation as possible up to 4.17 (along with a few scattered removals from beyond)
#preflight 61eefc77ba69a4fdb220bf23

#ROBOMERGE-AUTHOR: marc.audy
#ROBOMERGE-SOURCE: CL 18712765 in //UE5/Release-5.0/... via CL 18712784 via CL 18713147
#ROBOMERGE-BOT: UE5 (Release-Engine-Test -> Main) (v903-18687472)

[CL 18713191 by marc audy in ue5-main branch]
2022-01-24 15:07:48 -05:00
axel riffard
a5f7151d7e Unshelved from pending changelist '18530545':
Release the viewcontroller holding the splashcreen storyboard when it's no longer displayer.
# fyi wei.liu
#rb jack.porter
#jira UE-137601
#preflight 61dff0b2a11335e9c4aa263c

#ROBOMERGE-AUTHOR: axel.riffard
#ROBOMERGE-SOURCE: CL 18594779 in //UE5/Release-5.0/... via CL 18594794 via CL 18594803
#ROBOMERGE-BOT: STARSHIP (Release-Engine-Test -> Main) (v899-18417669)

[CL 18596612 by axel riffard in ue5-main branch]
2022-01-13 10:05:36 -05:00
Leon Huang
109e2cd26d Introduced screen reader navigation policies. This allows the screen reader to navigate around UI elements on the screen separate from regular Slate navigation.
- Introduced IScreenReaderNavigationPolicy. This is an interface class that helps the screen reader navigate to the appropriate target accessible widget.
- Introduced FScreenReaderDefaultNavigationPolicy. This is a policy that all FScreenReaderUsers have by default. It helps the screen reader user find target accessible widgets that are enabled and can be focused on.
- Introduced focus navigation functions to FScreenReaderUser. This is the means clients can control and shift accessible focus for FScreenReaderUsers.
- IAccessibleWidget can now retrieve the logical next and previous widget in the accessible widget hierarchy. This functionality is similar to that of mobile screen readers like Voiceover and Android Talkback which allow users to navigate around the UI hierarchy with left and right swipes.
- IAccessibleWidget can now search for a target widget from a source widget based on a search criteria. This is useful for searching for widgets by characteristics (such as enabled state, widget type etc).
- Fixed a small bug in accessible focus where an accessible widget with application focus cannot receive accessible focus again and have its contents announced to the end user.
#rb: Prajwal.Manjunath
#jira: UE-130926
#preflight: 61baf981440d71c977b3089a

[CL 18477319 by Leon Huang in ue5-main branch]
2021-12-16 13:57:14 -05:00