Commit Graph

272 Commits

Author SHA1 Message Date
Ed Maste
39b91d8875 UI: Restore XDG config path update for FreeBSD
Restore move_to_xdg from commit ba02e065fe to migrate from pre-XDG
config path $HOME/.obs-studio on FreeBSD.
2024-10-18 18:19:19 -04:00
Ed Maste
b654dba30a UI: Catch error from copy in MigrateGlobalSettings
During development on FreeBSD I encountered an uncaught exception abort
from the copy in MigrateGlobalSettings.  Catch the error and print a
user-facing message:

error: Unable to migrate global configuration - copy failed.
2024-10-16 11:37:22 -04:00
PatTheMav
3995b4662d UI: Fix crash when providing scene collection or profile via CLI
When a starting scene collection or profile is provided, current code
would crash as the corresponding collections and management functions
do not exist yet (they are tied to OBSBasic, which is not initialized
that early in the program execution).

This change moves the checks for command line arguments into OBSBasic
into the parts responsible for initializing profiles and scene
collections and check for arguments provided via command line there.
2024-10-10 16:38:33 -04:00
test
15cd31fdbd UI: Fix settings mismatch 2024-10-07 14:13:25 -04:00
Ryan Foster
a1fbf1015f clang-format: Increase column limit from 80 to 120 2024-10-04 18:19:27 -04:00
PatTheMav
32cfa1626f UI: Fix missing support for portable configuration files
Windows and Linux allow the storage of configuration files relative
to the binary location, which is enabled by default on Windows and has
to be explicitly enabled on Linux.

This was originally conflated with the LINUX_PORTABLE build setting
which also allowed the application itself to be run from non-default
locations on a Linux system.

This change reintroduces the functionality behind the
ENABLE_PORTABLE_CONFIG build setting on Linux.

It also adds necessary code to make this setting compatible with the
recently introduced relocatable settings code changes:

When portable mode is enabled, user configuration, scene collections,
and profiles are stored in the config directory created for portable
mode.
2024-09-26 14:39:44 -04:00
PatTheMav
5779b52d92 UI: Fix config class mismatch in OBSApp class 2024-09-18 16:29:01 -04:00
PatTheMav
3e0592dc20 UI: Rewrite scene collection system to enable user-provided storage
This change enables loading scene collections from locations different
than OBS' own configuration directory.

It also rewrites profile management in the app to work off an in-memory
collection of profiles found on disk and does not require iterating
over directory contents for most profile interactions by the app.
2024-09-12 16:18:46 -04:00
PatTheMav
607d37b423 UI: Rewrite profile system to enable user-provided storage location
This change enables loading profiles from locations different than
OBS' own configuration directory.

It also rewrites profile management in the app to work off an in-memory
collection of profiles found on disk and does not require iterating
over directory contents for most profile interactions by the app.
2024-09-12 16:18:46 -04:00
PatTheMav
2635cf3a2a UI: Split global config into app and user config
This introduces a split of the current single ConfigFile instance for
all configuration into two separate instances.

The app config instance contains system-wide settings that mainly
concern the working of the app itself, whereas the user config instance
contains settings actually exposed to the user for the configuration.
2024-09-12 16:18:46 -04:00
derrod
834c15e717 UI: Remove legacy Qt workarounds (Ubuntu 22.04) 2024-08-23 13:44:04 -04:00
derrod
f6097cacfb UI: Remove legacy migrations 2024-07-29 18:54:01 -04:00
tytan652
5eb10135da UI,shared: Move SliderIgnoreScroll to its own directory 2024-07-27 07:38:36 +02:00
tytan652
48f139729f UI,shared: Move Qt Wrappers to its own directory 2024-07-27 07:38:36 +02:00
derrod
00c68981ab UI: Check VC++ Runtime version on startup 2024-06-10 16:51:50 -04:00
derrod
51e3bd5e3d UI: Remove unnecessary string copy from log filter 2024-06-08 14:06:23 -04:00
jcm
bd36daa395 UI: Address logging buffer size discrepancies 2024-06-07 17:38:06 +02:00
tytan652
116107bc86 UI: Fix Qt platform override in CMake 3
This override is still needed until Qt minimum version requirement is
increased to at least 6.3.0.

ui-config.h.in and CMake 2 are modified to avoid USE_XDG redefinition in
CMake 3.
2024-06-05 18:33:47 -04:00
Ruwen Hahn
43a1b30994 UI: Increase size of log buffer
Dumping config json from nlohmann requires more than 4096 bytes
2024-06-04 18:49:05 -04:00
derrod
4503f0a056 UI: Add Hybrid MP4 to format selection 2024-05-26 23:11:48 +02:00
tytan652
34d577d748 UI: Enforce completely Fusion Qt style on Linux
As of 8dcfae9a39, indicating the base
style to the proxy is completely functional.

It also bypasses QT_STYLE_OVERRIDE and -style, but since the system
theme is no longer available on Linux this is a non-issue.
2024-05-25 16:58:26 -07:00
Warchamp7
aba600cec0 UI: Move VolumeSlider widget to volume control 2024-05-23 18:55:43 -04:00
derrod
503968671d UI: Add composable themes feature
Co-authored-by: Warchamp7 <warchamp2003@hotmail.com>
2024-04-21 00:01:16 -04:00
derrod
260b5ae137 UI: Cancel session end request on commitDataRequest() signal 2024-01-23 22:01:24 -06:00
derrod
ba25bc65c9 UI: Disable safe mode when --multi is used 2023-11-17 15:31:36 -05:00
derrod
ae148b60a8 UI: Add 'theme:' prefix to Qt search paths 2023-10-10 17:19:02 -03:00
Norihiro Kamae
1476033684 UI: Remove unused static functions
The function convert_14_2_encoder_setting was replaced by
convert_28_1_encoder_setting.
2023-08-26 16:52:35 -07:00
Wooster
655cc23d7f UI: Fix capitalization of "WebSocket" 2023-08-19 16:45:16 -07:00
derrod
4e5be319e4 UI: Move restart to end of main() 2023-08-18 07:16:41 -07:00
Lain
346b93c9c4 Merge pull request #8689 from gxalpha/no-more-signal-slot-macro
UI: SIGNAL and SLOT macros begone!
2023-07-29 16:32:56 -07:00
derrod
72284a4837 UI: Migrate branches to nlohmann JSON 2023-07-23 09:24:33 +02:00
derrod
2f5038318e UI: Remove D3D11 shader cache folder creation 2023-07-22 18:04:08 -07:00
Richard Stanway
e7a3ffdb54 libobs-d3d11: Implement shader cache
Co-Authored-By: derrod <dennis@obsproject.com>
2023-07-22 16:59:31 -07:00
derrod
396cfdb416 UI: Add Safe Mode 2023-07-21 23:22:07 +02:00
gxalpha
e467f17501 UI: Replace SIGNAL and SLOT macros in obs-app 2023-07-21 13:16:04 +02:00
gxalpha
79ab526f03 UI: Remove remaining Qt 6 ifdef 2023-07-19 11:56:54 -04:00
derrod
dcc07cfe4e clang-format: Set AllowAllConstructorInitializersOnNextLine to false 2023-07-15 16:14:55 -07:00
gxalpha
a4834efde9 UI: Remove Qt 5 ifdef guards and code 2023-07-12 13:22:13 -04:00
Norihiro Kamae
c053216824 UI: Remove move_to_xdg
The configuration directory was $HOME/.obs-studio until version 0.10.1
and then moved to XDG's configuration path by ba02e065fe.
The function move_to_xdg was introduced to move the old configuration
directory and left almost untouched for 8 years.
2023-06-09 04:51:10 -07:00
PatTheMav
2966c4030e libobs: Use static library for version string information
Switching to a static library that contains version information as
const char strings has multiple benefits:

* The version information provided externally via compiler definitions
  will fail compilation early if malformed
* An updated version string (which will happen with every commit) will
  not invalidate existing compilation units, because only the static
  library is affected by the change
* An update of the version change just requires a recompilation of the
  static library and a linker update
* An update of the version will _not_ infect the rest of the codebase
  (as it does currently, because everything includes obsconfig.h one
  way or another)
* Other modules which used the macro definition directly have been
  updated as much as possible to use the proper getter method from
  `libobs` instead (some Windows-specific modules use preprocessor
  string composition, the value has been added as a compiler definition
  directly in those cases)
* Because the impact of a version change due to a commit hash change
  is limited to the static library, ccache hit rates should be
  improved considerably
2023-05-27 16:48:24 -07:00
Norihiro Kamae
63e0bff5e6 UI: Fix crash when receiving multiple SIGINT
When there are two or more SIGINT signals were sent to obs, obs crashes
because the 2nd SIGINT calls `close` though the main window has been
deleted.
2023-05-23 04:17:11 -07:00
Lain
106c7aa61f Update copyrights/names 2023-05-20 01:31:18 -07:00
gxalpha
2ab326d2cd UI: Redirect Qt log messages to OBS log 2023-05-13 17:09:32 -07:00
Richard Stanway
820fba2d7f UI: Remove unnecessary variables type conversions
Detected by PVS Studio.
2023-04-05 00:40:31 +02:00
derrod
5a375defa8 UI: Rework recording format handling 2023-04-04 00:54:28 +00:00
cg2121
3a610c698e UI: Remove UNUSED_PARAMETER where unnecessary
Since cpp allows removing the unused parameters from the function name,
UNUSED_PARAMETER is not needed, unless it is in an ifdef.
2023-04-01 16:54:02 -07:00
Ryan Foster
60139cbdfe Revert "UI: Remove bitness strings"
This reverts commit 64d4ae0106.
2023-04-01 16:35:10 -07:00
Jim
39afa665a1 UI: Always print debug log to stdout if Debug build
Makes it easier to debug certain issues when building on non-Windows
machines.
2023-03-25 22:51:25 -07:00
Richard Stanway
5182368009 UI: Properly handle SIGINT on non-Windows platforms
Running Qt code in a signal handler is not safe. Per the Qt docs, we
instead create a pair of sockets and a QSocketNotifier so that the
signal handler can notify the main thread which can process the exit
request without risk.

Reference: https://doc.qt.io/archives/qt-6.3/unix-signals.html
Reference: https://man7.org/linux/man-pages/man7/signal-safety.7.html
2023-03-25 16:17:02 -07:00
derrod
5083c2a2e2 UI: Remove Windows 7 browser hwaccel check 2023-03-18 15:19:48 -07:00