Commit graph

3481 commits

Author SHA1 Message Date
derrod 09024e9c74 UI: Add Crop to Bounds checkbox to transform dialog 2023-12-16 18:00:11 -06:00
cg2121 59766ee4ff UI: Remove SignalBlocker
Since QSignalBlocker does the same thing, remove SignalBlocker.
2023-12-16 17:10:57 -06:00
BGM99 04788d30e2 UI: Fix resize cursor to respect item transformation 2023-12-16 18:19:20 +01:00
bin b9ce24aa56 UI: Fix QListWidget background color in property groups 2023-12-14 23:24:23 +01:00
cg2121 ef99553a7e UI: Disable edit transform if item is locked
The transform window was still accessible if the scene item
was locked.
2023-12-10 01:27:28 +01:00
cg2121 cd01120740 UI: Don't paste transform on locked item
This disables pasting transforms on an item that is locked.
2023-12-09 18:09:33 -06:00
PatTheMav e27b013d47 aja: Disable deprecated declarations warnings on macOS and Linux
Deprecation warnings have been investigated and have been deemed
non-malicious for the time being.
2023-12-06 17:27:12 +01:00
Translation Updater f674d17168 Update translations from Crowdin 2023-12-05 22:04:31 +00:00
Penwywern 3cc7dc0e7c UI: Fall back in case of invalid scene name on load 2023-12-04 05:06:42 -06:00
Nikola Jovic 21a906d7d9 UI: Fix checkbox misalignment on macOS in properties view 2023-12-02 21:18:36 +01:00
gxalpha e9ecb6c565 UI: Make replay buffer settings always visible in Simple Mode
Instead of a checkbox in the recording group that reveals the replay
buffer group when pressed, the replay buffer group now has its own
toggle that enables or disables the replay buffer.
2023-11-27 15:29:57 -06:00
gxalpha 7d55229bef UI: Add to lossless warning that replay buffer is unavailable 2023-11-27 15:29:57 -06:00
Matt 93f5b45be8 frontend-tools: Fix multiple signal-slot connections on Output Timer
When running an Output Timer multiple times, multiple signal-slot
connections would be made with the corresponding output stop event
functions. This would cause later Output Timers to terminate
unexpectedly early, due to the stop functions having been called
repeatedly on previous Output Timer runs while outputs were stopping.

There may still be an underlying bug with calling stop on outputs
repeatedly, but this change at least ensures that Output Timers only
call their stop functions once.
2023-11-20 17:02:14 -05:00
derrod cfd8d4c993 updater: Clear shader cache after updating 2023-11-20 04:32:56 -06:00
derrod ba25bc65c9 UI: Disable safe mode when --multi is used 2023-11-17 15:31:36 -05:00
田七不甜 5f512d5f25 UI: Fix UseStreamKeyAdv not display stream key and not hide button 2023-11-08 00:13:20 -06:00
Ryan Foster c0ee1e718d UI: Fix typo in Virtual Camera logging functions
cvam -> vcam
2023-11-07 19:09:25 -05:00
Penwywern a49b35c3de UI: Log Virtual Camera output type 2023-11-07 00:39:01 -06:00
Zulleyy3 Zulleyy3 c76760bc1c UI: Fix transform of sources in groups
Group resize is not deferred until adjustments are completed by a
mouseReleaseEvent in certain cases, resulting in unexpected movement of
sources that are part of a group as they are resized or stretched
beyond group bounds.

The bug can be described/reproduced as follow:

1. The user selects within a group in the sources dock
2. The user moves their mouse over the selected source such that the
   cursor would change.
   - This results in a cursor update and a call to GetStrechHandle()
   - as the source is part of a group, stretchGroup will be set to the
    group of the source

3. The user clicks on the canvas without touching a stretch/rotation
   handle
   - A mouseReleaseEvent is fired
   - obs_sceneitem_defer_group_resize_end is called on the group as
     stretchGroup is still defined from earlier
   - the defer_group_resize member of the group will become negative
   - The deferal check in resize_group (obs-scene.c) will always pass
     now
4. When scaling or rotating the source close to the group bounds, the
   group bounds will now dynamically update causing the source in to fly
   off the canvas.

Resolves: https://github.com/obsproject/obs-studio/issues/9754
2023-11-04 18:06:44 -05:00
gxalpha 60c77aa915 UI: Replace SourceTreeSubItemCheckBox class with Qt property 2023-10-28 10:22:38 -03:00
Penwywern 1a88cdb00d UI: Fix AMF AV1 simple recording presets 2023-10-27 14:10:20 -04:00
Ryan Foster b4c36c0530 UI: Remove iCCP data from PNGs
Loading these PNGs in libpng 1.6+ results in the warning:
libpng warning: iCCP: known incorrect sRGB profile

This is probably caused by saving an ICC Profile with the program used
to make the image, and that ICC Profile is considered invalid by libpng.

Removing the iCCP data resolves this.
2023-10-26 16:59:06 -04:00
jpark37 6aaf0358ca decklink-output-ui: Decouple DeckLink output state
Didn't realize OBS could output both program and preview views at the
same time with multiple devices.

Also remove render callbacks earlier on stop to avoid use-after-free.
2023-10-25 01:11:32 -05:00
Rodney 5ebd3ee6d3 UI: Add missing NULL check for skipUpdateVer 2023-10-17 11:17:07 -04:00
Norihiro Kamae 20b8deba2d frontend-tools: Remove unused startAtLaunch variable 2023-10-14 18:35:38 -05:00
gxalpha 44f3f79296 UI: Convert QTStr macro to inline function
Using inline functions improves IDE integration and avoids potential
pitfalls of that using macros has.
2023-10-12 11:45:45 -04:00
Paul Hindt d8f533538f UI: Fix compile error due to use of strlen in constexpr 2023-10-11 01:31:02 +02:00
derrod 625277ace3 UI: Use theme path prefix in status bar 2023-10-10 17:19:02 -03:00
derrod a2db8876fc UI: Use theme path prefix in source tree 2023-10-10 17:19:02 -03:00
derrod 1906a14b90 UI: Update themes to use 'theme:' prefix for non-qrc files 2023-10-10 17:19:02 -03:00
derrod ae148b60a8 UI: Add 'theme:' prefix to Qt search paths 2023-10-10 17:19:02 -03:00
Translation Updater 0d450a34a0 Update translations from Crowdin 2023-10-10 13:34:41 +00:00
gxalpha baa78b36ef UI: Enable "Paste Filters" after copying from scenes or mixer
Fixes an issue where if no filters had previously been copied and the
user copies a filter from either the scene tree or the audio mixer, the
"Paste Filters" action would not be available until the Edit menu
reloads (e.g., by selecting another source in the source tree).
2023-10-08 10:59:00 -06:00
PatTheMav 2226292adc UI: Initialize YouTubeAppDock synchronously to fix Qt runloop issues
The YouTubeAppDock uses its own cookie manager and thus requires a
running CEF instance before creating the dock. Unfortunately creation
of the dock itself and launching the associated browser instance are
coupled in the code.

The UI code to restore browser dock states runs _after_ this code and
unfortunately this is also the only way to ensure that if the user
has closed the YouTubeAppDock before that it stays closed on app
launch (the dock needs to exist in the Widget hierarchy for its state
to be restored).

Alas, outside of Windows, InitBrowserPanelSafeBlock uses a separate
local QEventLoop to block the main thread while still allowing UI
events to be processed to launch a CEF instance.

By this point in the code execution, the primary event loop has not
been started yet, so the event loop launched by
InitBrowserPanelSafeBlock temporarily becomes the main application
event loop, which initializes all Widgets, finds no active window
state for the widgets, and thus treats them as "visible", calls the
showEvent method on every browser dock, which thus loads the associated
websites.

The dock state is restored after all that, which leads to each browser
dock being "shown" (even though the main QApplication hasn't even
started yet), the associated sites are running (including audio and
video output) but then hidden again, which leads to surprising audio
output seemingly coming from "nowhere".

All browser docks call the browser initialization methods synchronously,
which has the benefit of not spinning up a premature event loop, and does
not trigger Qt view state changes before all Widgets have been
initialized. Having the YouTubeAppDock behave the same does thus not
negatively impact UX.
2023-10-08 02:00:38 +02:00
derrod e4587ae9bd UI: Cleanup remaining uses of old version macros 2023-10-06 17:21:51 -06:00
derrod 9f37258298 UI: Refactor Windows update check to always use LIBOBS_API_VER 2023-10-06 17:21:51 -06:00
derrod d78a05e124 cmake: Fix OBS_COMMIT not being set (Windows only) 2023-10-06 17:21:51 -06:00
Ryan Foster 02478d4939 UI: Use std::shared_ptr instead of QSharedPointer
Also use std::weak_ptr instead of QWeakPointer as needed.

Qt has been porting QSharedPointer and QWeakPointer to std::shared_ptr
and std::weak_ptr respectively. QSharedPointer is apparently 2x slower
than std::shared_ptr.

References:
 * https://bugreports.qt.io/browse/QTBUG-109570
 * https://codereview.qt-project.org/c/qt/qtbase/+/359678
 * https://codereview.qt-project.org/c/qt/qtgrpc/+/447780
 * https://codereview.qt-project.org/c/qt/qtbase/+/450134
 * https://codereview.qt-project.org/c/qt/qttools/+/450776
 * https://codereview.qt-project.org/c/qt/qttools/+/450777
 * https://codereview.qt-project.org/q/QSharedPointer
2023-10-04 18:36:20 -04:00
Ryan Foster 3d05d681b7 UI: Use C++11 ranged-for instead of Q_FOREACH
Qt has been porting uses of Q_FOREACH/foreach to C++11's ranged-for.
Let's do the same.

References:
 * https://doc.qt.io/qt-6/foreach-keyword.html
 * https://codereview.qt-project.org/q/Q_FOREACH
2023-10-04 17:58:02 -04:00
derrod 5dda04ad5e Revert "UI: Add workaround for Qt tooltip stylesheet bug"
No longer required as this was fixed in Qt 6.5.3.

This reverts commit d97950445e.
2023-09-29 18:00:04 +02:00
tytan652 46fc409843 UI: Fix IP settings order 2023-09-16 16:16:43 -07:00
Richard Stanway c71bbcf4d9 UI: Avoid using newlines in error messages
Some errors include HTML links directing users to e.g. driver updates
or further information. Using a raw newline instead of <br> causes Qt to
skip parsing the HTML, resulting in an ugly mess of HTML displayed to
the user instead of the intended links.
2023-09-12 17:54:42 -07:00
gxalpha 839461dc9b UI: Don't show native popup for YouTube auth message box
The native popup has the problem that it doesn't work for links, leaving
us with an unclickable text where a link should be. Qt 6.6 has an option
to disable the native dialog, so let's add this to make the link
clickable again.

Co-authored-by: derrod <dennis@obsproject.com>
2023-09-11 10:07:16 -07:00
Richard Stanway e5472c775c UI: Standardize spelling of closable, fix typo 2023-09-11 09:56:27 -07:00
Richard Stanway d8bf21de2f UI: Add cleanup of stats callback on window close
Moving the cleanup to OBS_FRONTEND_EVENT_EXIT in #8735 only handled the
cleanup from the dockable window, as the regular stats window is deleted
on close when the UI is shut down. This caused an event handler leak
each time the window is manually closed, resulting in crashes. This code
looks a bit wrong since we delete the same handler in multiple places,
but this is due to the code being used by both the dock (non-closable)
and the window (closable). The OBS_FRONTEND_EVENT_EXIT handler handles
cleanup from the dockable stats window, and the window close handler now
handles cleanup from the non-dockable stats window.
2023-09-11 09:19:54 -07:00
gxalpha af7d8482e5 UI: Remove unused ExpandCheckBox
ExpandCheckBox was introduced in 88b6c63, but the seemingly replaced by
SourceTreeSubItemCheckBox during development. This means that it became
completely unused.
2023-09-09 09:38:42 -07:00
derrod eb89f7c3ab UI: Create/Delete YouTube Dock when switching profiles 2023-09-06 21:50:12 -07:00
gxalpha 3ff7cd5625 UI: Untangle ifdef'd if-statement to un-confuse Xcode
Like many IDEs, Xcode has this feature where it shows the declaration of
the method currently being worked in. However it gets confused by scopes
starting inside of preprocessor guards and ending outside them,
resulting in the declaration of OBSBasic::ReceivedIntroJson always being
shown in window-basic-main.cpp from that method downwards. We can work
around that by starting and ending the if-scope outside of the ifdefs.
2023-09-06 21:48:52 -07:00
Ryan Foster 3239e2a1f2 UI: Restrict regex pattern for OAuth secrets
The current regex pattern will successfully match if the cache variable
contains the pattern anywhere inside the string. Let's restrict the
regex pattern such that it requires the pattern to be precisely between
the beginning and end of the string with no other characters in between
those anchor points.
2023-09-06 15:06:59 -04:00
derrod d97950445e UI: Add workaround for Qt tooltip stylesheet bug 2023-09-06 13:08:37 -04:00
derrod 391eb5fac5 UI: Fix settings Apply button always being enabled 2023-09-06 12:29:25 -04:00
derrod aed8e2384d updater: Remove non-error logging from multithreaded code 2023-09-05 15:02:41 -04:00
derrod ef45248e40 UI: Fix ifdef for YouTube dock integration 2023-09-05 12:06:46 -04:00
joelgerard 83c4f5383e UI: Increase YouTube API timeout
The OBS client side timeout for the YouTube API is too short. New
changes proposed to the YouTube API will cause this to fail for
creating a broadcast. Increase to a minimum of 60.
2023-09-05 10:06:18 -04:00
Lain 112adb0a73 UI: Fix stream key UI not showing when using stream key
In the settings window, when the user chooses to use a stream key
instead of connecting their account, it switches widgets to show the
stream key UI. However, when opening the settings window again after
having done that, it's supposed to continue to show the stream key UI,
and that functionality was broken by obsproject/obs-studio#9272. It did
this because OBSBasicSettings::ServiceChanged() no longer called
reset_service_ui_fields() because the lastService member variable was no
longer set to empty in OBSBasicSettings::LoadStream1Settings().

This fixes it by just adding a parameter to
OBSBasicSettings::ServiceChanged() to make it forcibly reset the fields
when loading stream settings.
2023-08-31 23:39:26 -07:00
derrod 632f40c4d5 UI: Fix source enumeration in source select aborting prematurely
Hidden sources should be ignored, but the enumeration should continue.
2023-08-28 22:39:53 +02:00
derrod 028b3c12cf updater: Static analysis cleanups 2023-08-26 16:53:14 -07: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
Ryan Foster ece8df2ace UI: Increase minimum output resolution to 32x32
Some hardware encoders fail in indecipherable ways if you try to at
certain low resolutions such as 17x17 or 19x19, but works at 20x20.
However, there is no good way to determine what the minimum working
resolution is for every possible encoder. There isn't that much
difference between 8x8 and 32x32, except that the latter will reduce or
eliminate such odd failure cases, so let's increase the minimum required
output resolution by just a little bit.
2023-08-26 16:32:24 -07:00
田七不甜 2dbd7bf7ff UI: Add stream key tooltip in the auto-config wizard 2023-08-26 16:15:11 -07:00
田七不甜 01ecdd989c UI: Fix stream key tooltip in the settings page 2023-08-26 16:15:11 -07:00
Ihor Kalnytskyi 08f5a7bd4d UI: Fix crash in YoutubeAuth
YoutubeAuth::chat is a raw pointer that is uninitialized. Most of the
time it doesn't matter, since the object it points to is created at the
application start. However, in case of Wayland (Linux), CEF is not
initialized (because it's not supported) and the chat object will never
get created.

This patch fixes crash on Wayland by initializing `chat` to `nullptr`.

Co-authored-by: Roman Podoliaka <roman.podoliaka@gmail.com>
2023-08-25 19:10:06 -04:00
Norihiro Kamae cdced774e8 Revert "UI: Support DnD overlay in linuxbrowser"
This reverts commit aeed4a3aa1.
The source type `browser_source` is now available for all supported
platforms so we don't need to fallback to `linuxbrowser-source`.
2023-08-24 15:20:36 -04:00
tytan652 a4bef329c2 UI: Replace remaining enc-amf reference
Since enc-amf was removed, this reference causes issue by flagging H264
AMF as unsupported forcing a fallback to x264.
2023-08-22 14:24:46 -04:00
cg2121 b19f922747 UI: Fix alignment of status bar message
The status bar message was not vertically aligned properly to
other widgets in the status bar. We have to implement our own
message system here, as the default status bar in Qt has hardcoded
paddings.
2023-08-21 17:46:25 -03:00
cg2121 610990270f UI: Center vertical volume control buttons
The mute and config buttons were not vertically centered.
2023-08-21 17:38:31 -03:00
Norihiro Kamae b2a8e0a99b UI: Use the latest version when dropping files 2023-08-21 07:23:09 -07:00
gxalpha b3485dd354 cmake: Mark source lists in feature files sortable 2023-08-19 16:57:21 -07:00
Wooster 655cc23d7f UI: Fix capitalization of "WebSocket" 2023-08-19 16:45:16 -07:00
derrod 3c28903979 UI: Log if user is ignoring service limits 2023-08-19 16:37:08 -07:00
Lain a44ab2efcc UI: Add timer to NewYouTubeAppDock()
CEF apparently doesn't like it and is unable to handle when you
destroy/recreate CEF instances very quickly, so... let's just put a
timer on this insanely terrible function. I guess. Whatever.
2023-08-18 11:28:16 -07:00
derrod 4e5be319e4 UI: Move restart to end of main() 2023-08-18 07:16:41 -07:00
Lain b8d85d84a4 UI: Fix potential null pointer dereference
If you're using an encoder from a plugin, and you remove that plugin,
this value will be null, causing a crash. (Lain note: I realize that
this isn't the best solution to this problem, though there really isn't
any way to infer what type of encoder the prior encoder was. Should also
save the encoder type as additional setting metadata in future
versions.)
2023-08-17 17:06:24 -07:00
Norihiro Kamae ad740735d2 UI: Fix memory leak in OBSQTDisplay
In my previous commit fd502cbd4, SurfaceEventFilter was not destroyed
and caused memory leaks.
2023-08-17 11:46:28 -07:00
derrod a06d6893b9 UI: Remove silent OpenGL fallback on Windows 2023-08-16 11:03:00 -07:00
Jimi Huotari f83b0d93f1 UI: Fix compiling without nlohmann JSON
After commit 8955338624, 'UI/update/models/whatsnew.hpp' is included
unconditionally, even with 'ENABLE_WHATSNEW=OFF', which breaks
building OBS Studio without nlohmann JSON.
2023-08-16 19:43:46 +02:00
Lain c8d95005c1 UI: Fix unnecessary GetCurrentScene() call
Missed this with the parent commit; the scene variable is now already
available, thus there is no need to call GetCurrentScene() twice.
2023-08-15 17:20:44 -07:00
Lain e0f7bcaf3f UI: Hold reference to scene when drawing spacers
Just holds a reference to the scene as a safety precaution.
2023-08-15 17:11:23 -07:00
PatTheMav 8d82263513 UI: Fix possible race condition in DrawSpacingHelpers
The use of GetCurrentSceneItem can lead to a race condition between
the graphics thread (where this function will be run) and the main UI
thread, as both access the scene list model and iterate through its
members which can change during iteration (as there is no lock around
its access).
2023-08-15 16:05:04 -07:00
gxalpha 518bdc7af1 UI: Fix transform shortcuts with multiple items selected
Firstly, removes the UpdateTransformShortcuts() method introduced in
c33fa8b which was trying to re-implement the behavior of
UpdateEditMenu().
Secondly, updates UpdateEditMenu() to account for sources without video.
Sources without video shouldn't be able to have their transform edited,
copied, pasted, or changed in any other way (because they don't have
one).
2023-08-15 15:56:43 -07:00
derrod 3e29844af7 UI: Set advanced audio encoder to invalid if missing 2023-08-15 15:54:07 -07:00
Lain fee4f2dc48
Merge pull request #9435 from norihiro/qtdisplay-destroy-at-surface-event-3
Fix crash at render_display while shutdown on macOS
2023-08-15 15:49:54 -07:00
jpark37 bb12fe9db5 decklink: Add HDR playback support 2023-08-15 13:15:45 -07:00
Ryan Foster f049d04af4 UI: Store dock titles in BrowserDock instead of relying on Qt
Attempting to set the window title of a BrowserDock that is closed, then
opening the BrowserDock, would show that BrowserDock with an incorrect
title. We can handle this by overriding the showEvent of BrowserDock and
manually setting the window title after the showEvent is called,
hopefully ensuring that we are only setting the window title on a window
that exists.
2023-08-15 12:27:18 -04:00
Ryan Foster 25b97df6eb UI: Update text for custom browser dock menu items manually
Instead of relying on the dock's having their window title already set
for the menu items to be updated, let's just manually update the menu
item text ourselves when updating the item.
2023-08-15 12:27:18 -04:00
Ryan Foster 20e4f0cad3 UI: Track custom browser dock names internally
This is a workaround for a change in Qt behavior between 6.5.1 and
6.5.2[1] which affected the outcome of attempting to set the window
title of a window that is not currently open. In Qt 6.4.3 and 6.5.1, the
window title would be set. In Qt 6.5.2, the window title will become
NULL/empty.

Instead of relying on Qt to have valid titles for custom browser dock
windows that we manage, let's track the names ourselves.

[1]: c153066baa
2023-08-15 12:27:18 -04:00
Matt Gajownik 7d9f8e7cac UI: Set browser dock title in constructor
Works around a bug in Qt where setWindowTitle called on a native window
that hasn't been initialised yet causes the title data to be lost,
resulting in the window's title never being set.
2023-08-15 12:27:18 -04:00
Norihiro Kamae dfce9b929a
UI: Fix crash at resizing display followed by destruction on macOS
The resize event was triggered during the shtudown of OBS. A commit
9f330050ef moves the actual resize code in `gl_update` to the main
thread without synchronizing between the main thread and the graphics
thread. When the display context is destroyed just after the resizing,
the delayed resize code can read the destroyed display context.
As a workaround, this commit will destroy the display context at the
earlier timing of the shutdown process.
2023-08-15 14:01:11 +09:00
Norihiro Kamae fd502cbd4d
UI: Fix crash at render_display while shutdown on macOS
The display context was sometimes created again by a resize event after
destruction from `OBSBasic::closeEvent`. That resulted in the display
context alive until reaching the destructor of the `OBSQTDisplay` class
and caused a crash in `render_display` on macOS. To avoid this, destroy
the display context at the event `SurfaceAboutToBeDestroyed` and let not
create the display context again.
2023-08-15 13:40:09 +09:00
Norihiro Kamae fa17168ba2
UI: Removes the workaround of not receiving expose event
The commit e67fdbca79 is a workaround for QtWayland bug that the
`QEvent::Expose` was never received on a certain condition.
The bugfix was introduced to QtWayland 6.1.0 so that the workaround is
not necessary for now.
2023-08-15 13:12:34 +09:00
Translation Updater ecf914dd67 Update translations from Crowdin 2023-08-13 14:09:15 +00:00
prgmitchell 2a9b9c9298 UI/importers: Ignore empty Streamlabs hotkeys
Ignore empty hotkeys when importing a scene collection file from
Streamlabs Desktop.
2023-08-12 22:31:01 -04:00
Matt Gajownik b429d00440 UI: Show link to release notes in Help menu 2023-08-12 16:46:38 -07:00
Friedhelm Birth a599dd50f6 UI: Add high frame rate 119.88 fps to capture device properties 2023-08-12 16:16:24 -07:00
Friedhelm Birth 11ae49da73 UI: Add high frame rates (120, 144, 240) to general video properties 2023-08-12 16:16:24 -07:00
gxalpha 6721154924 UI: Use QCheckBox::toggled signal for checkbox changes
Like in 4f8b17d61, "toggled" is the signal that listens for changes
however they may have happened (including through things like
accessibility software), whereas clicked only is emitted on mouse
clicks. We should react to any kind of change, whatever prompted it.
2023-08-12 13:58:06 -04:00
gxalpha d2ef4d21b3 UI: Don't cap auto-config wizard FPS whole number precision at 2
Capping the precision for whole numbers results in scientific notation
being used for any number that's larger than what can be displayed with
the given precision. In case of 2, that would be anything larger than
99, resulting in 120 for example to be shown as 1.2e+02.
Let's not cap the precision for whole numbers ourselves and just use the
default value (which at the time of writing would be 6).
2023-08-11 21:36:44 -04:00
gxalpha 4f8b17d612 UI: Use QGroupBox::toggled signal for group changes
The QGroupBox::clicked is specifically for mouse clicks. This means that
it's not emitted if the "checked" property is modified through other
means than the mouse, for example programatically or through
accessibility software like VoiceOver.
However, we do want to catch such events, so the QGroupBox::toggle
signal (which as per the Qt documentation is the notified signal for the
"checked" property) is the appropriate one to use.
2023-08-11 21:10:11 -04:00
gxalpha 49ef1d4b98 UI: Set loading to true when loading accessibility settings
When loading a settings pane, "loading" should be set to true to stop
signals being emitted by settings changes to trigger while the settings
are loading. This should have always been set here as well, but wasn't
detected so far because currently there are no settings in accessibility
that have signals connected that track changes.
2023-08-11 21:10:11 -04:00
Lain b79e6d219f UI: Fix YouTube not saving stream key in auto config
Commit 85f9a8661b did not take into account whether YouTube was using a
stream key or not, it would prevent the auto-configuration dialog from
being able to save a YouTube stream key if the user opted to enter in a
stream key instead of connecting their YouTube account.

This simply fixes that by checking to see whether or not the user fully
connected their account or not.

Fixes obsproject/obs-studio#6406
2023-08-11 16:01:37 -07:00
gxalpha b962daa3c8 UI: Use static function instead of macro to set color
Macros can be hard to read and are usually not very friendly to use in a
debugger. Using a static function instead gives the advantage of better
syntax highlighting in IDEs and better debugger support.
2023-08-11 11:42:18 -04:00
derrod 014f7683cf updater: Pass through parameters to restarted OBS instance 2023-08-11 00:34:36 +02:00
derrod 38f41f4f94 UI: Copy OBS command line arguments to updater launch 2023-08-11 00:34:36 +02:00
PatTheMav 7628265099 Update .clang-format rules for ObjC files for version 16 2023-08-10 17:12:30 -04:00
Ryan Foster 64139a6bbd CI: Update to clang-format 16
This commit also modifies UI, libobs, and plugins.
2023-08-10 16:07:25 -04:00
gxalpha 2404036575 UI: Make simple mode settings warnings float at bottom of page 2023-08-09 20:38:59 -04:00
tytan652 db8ae46ca8 UI: Avoid showing YouTubeAppDock each time settings are updated 2023-08-05 18:32:18 -07:00
田七不甜 e8dbeede76 UI: Make title bar "SAFE MODE" translatable 2023-08-05 17:21:22 -07:00
Ryan Foster 2f8ea190b2 UI: Update CMake minimum to 3.22
Since Ubuntu 22.04 is now our minimum supported Ubuntu version, and it
has CMake 3.22, let's make CMake 3.22 the minimum CMake version.
2023-08-05 16:45:46 -07:00
tytan652 049f4454d4 UI: Fix YouTubeAppDock restore dock state 2023-08-05 16:44:16 -07:00
gxalpha 6a42d88ca7 UI: Don't call obs_source_get_output_flags on a NULL source 2023-08-05 16:30:44 -07:00
Lain 78cb2aa361 UI: Fix case where cef func may not be present
Due to a particular... plugin we all know and love, the new
QCefWidget::executeJavascript() function may not actually be present as
it should be. So, we have to verify that it's available, and only use it
in that case.
2023-08-05 04:35:31 -07:00
tytan652 c946090203 UI: Use new add dock path for YouTubeAppDock 2023-08-05 03:46:50 -07:00
Lain e86b2950a2 UI: Fix build error (forgot macro) 2023-08-03 18:43:01 -07:00
Lain 0c6fa0a2ba UI: Fix YouTubeAppDock crash
Apparently the YouTube app dock thing didn't take into consideration the
fact that the user may have the browser source available, but may not
have browser docks available (via the `cef` global). This is because
certain system configurations do not support browser widgets, such as
Wayland on Linux.

(Lain note: There's multiple things I'm unhappy about here. I'm mostly
going to blame myself for multiple reasons.)
2023-08-03 18:25:25 -07:00
Lain 9d2715fe72 frontend-tools: Disable properties deferring in script dialog
Prevents scripts from being able to defer their settings in the
properties view (because there's nothing to really defer to).
2023-08-03 16:28:00 -07:00
Lain 2a2472e326 UI: Add func to disable properties view deferring 2023-08-03 16:27:55 -07:00
Lain d2d3e46e14 Revert "UI: Only defer property updates for input and transition sources"
This reverts commit 58fb63030c.

This is not the ideal fix for the fact that scripts can use a deferred
update flag because it makes it so that filters in general cannot use
flags. We need to disable this via other means.
2023-08-03 16:09:31 -07:00
Yuriy Chumak 81b588137a UI: Add "YouTube Control Panel" dock panel
New dock panel with integrated youtube studio live control room.
This commit also modifies CI files.
2023-08-02 17:49:05 -07:00
derrod c3ac912065 UI: Refactor getting the default encoder for a format 2023-08-01 11:43:38 -07:00
derrod 036f7e8147 UI: Clean up remaining C-isms in FFmpeg utils 2023-08-01 11:43:38 -07:00
derrod 2f78bb7991 UI: Replace FFmpeg encoder alias with long name
The alias is not really helpful and sometimes confusing, e.g. for HEVC
(without libx265) it ends up being "hevc_nvenc (hevc_amf)" since it just
contains the name of the default encoder. So instead of using the name
of the default encoder, show the full name of the encoder instead.
2023-08-01 11:43:38 -07:00
derrod c20bf0271c UI: Refactor FFmpeg utilities codec/format enumeration 2023-08-01 11:43:38 -07:00
derrod c1cd268532 UI: Fix matching FFmpeg formats/codecs 2023-08-01 11:43:38 -07:00
derrod f0407dd1cd UI: Migrate from libff 2023-07-30 15:58:21 -07:00
cg2121 5e198db647 UI: Add new scene at current row
Instead of having a new scene at the bottom of the list, have
it added after the current item.
2023-07-29 17:20:47 -07:00
Exeldro 91f00eac87 UI: Split toggle preview program hotkey into hotkey pair 2023-07-29 16:48:25 -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
Lain 106e28d60f
Merge pull request #9302 from derrod/ui-update-nlohmann
UI: Migrate WhatsNew, update branches, and Windows update check to nlohmann JSON
2023-07-29 16:06:28 -07:00
Kurt Kartaltepe 6034aa4164 UI: Avoid auto config selecting QSV on linux
Previously we left the QSV -> x264 in the fallback function to deal with
the autoconfig wizard possibly selecting QSV outside of the UI. But this
actually runs for both recording and streaming every time obs starts,
reseting user's config if they selected QSV for recording.

Instead avoid recording from being selected in the UI and by the
auto-config wizard, and revert changes to the fallback function.
2023-07-27 02:34:30 -07:00
Penwywern 6f885770f8 UI: Fix crop on flipped sceneitems in bounding boxes
Same as previous commits, flipped sceneitems in bounding boxes ought
to be treated as not flipped for the purpose of UI interaction in
order to function correctly.
2023-07-25 15:28:16 -07:00
Penwywern a62993d513 UI: Fix drawing of pixel guides on flipped sceneitems in bounding boxes
Flip state of the item should be ignored when drawing guides for items
in bounding boxes, as the UI uses the countour of the bounding box, not
of the flipped item in it.
2023-07-25 15:28:16 -07:00
Penwywern 8d0f043ac6 UI: Fix draw and find of rot handle with bounding box and flip
The preview interaction and decoration of items inside bounding boxes
is based on the bounding box state, not on the item's state. As such,
the flip state of the item should be ignored when drawing and finding
the rotation handle, since the bounding box itself isn't flipped, only
the item inside the bounding box.
2023-07-25 15:28:16 -07:00
Penwywern 28a48c048d UI: Fix rotation handle find angle
The angle at which the rotation handle is drawn is independant from the
sceneitem's flip. As such, this changes `FindHandleAtPos` to use the rotation
angle of the item, free of its flip, instead of doing post-rotation
corrections. This fixes a bug where when the item was horizontally flipped,
the handle was not "found" at its drawn location.
2023-07-25 15:28:16 -07:00
James Hurley 488a96bc4b UI: Add IPv4 / IPv6 selection setting
This commit adds a field in Settings -> Advanced called
'IP Address Family' that allows users to select IPv4 and
IPv6, IPv4 Only, or IPv6 Only.
2023-07-24 17:10:30 -07:00
derrod 8955338624 UI: Migrate WhatsNew to nlohmann JSON 2023-07-23 09:24:33 +02:00
derrod 72284a4837 UI: Migrate branches to nlohmann JSON 2023-07-23 09:24:33 +02:00
derrod 01b21f67ff UI: Migrate Windows update check to nlohmann JSON 2023-07-23 08:54:17 +02:00
derrod 8ec0d7fd1b updater: Update manifest struct for use in UI 2023-07-23 08:54:17 +02:00
derrod 2f5038318e UI: Remove D3D11 shader cache folder creation 2023-07-22 18:04:08 -07:00
derrod d1dd7dd6d3 updater: Migrate to nlohmann JSON 2023-07-23 02:18:53 +02:00
Richard Stanway e7a3ffdb54 libobs-d3d11: Implement shader cache
Co-Authored-By: derrod <dennis@obsproject.com>
2023-07-22 16:59:31 -07:00
Lain 2f9df1372d
Merge pull request #8455 from derrod/safe-mode
Add Safe Mode
2023-07-22 16:56:40 -07:00
derrod bdc2da6e48 updater: Update installed version in registry 2023-07-22 16:33:19 -07:00
gxalpha d25a4ddae1 UI: Fix remaining status bar nits
Amends 1c8407183 to address the remaining points brought up on the Pull
Request that were not changed before merging.
2023-07-22 16:24:30 -07:00
gxalpha 633b9e39f7 UI: Don't clear lastService immediately after setting it
Fixes a bug where when you clicked "Show more..." in the service
settings combobox, the currently selected service would be changed to
the first service in the list.
2023-07-22 16:19:26 -07:00
derrod 396cfdb416 UI: Add Safe Mode 2023-07-21 23:22:07 +02:00
gxalpha a3991f9db8
UI: Replace SIGNAL and SLOT macros for HookWidget methods 2023-07-21 13:19:52 +02:00
gxalpha ef26f14f18
UI: Replace SIGNAL and SLOT macros for AddProjectorMenuMonitors method
A small refactor of AddProjectorMenuMonitors, as template functions need
to be fully defined in header files.
Also makes the function static as there is no point of it being a
non-static member function. In theory it could also be moved out of
OBSBasic but there isn't really a better place for it so let's leave it
where it is for simplicity.
2023-07-21 13:19:52 +02:00
gxalpha 61781d154d
UI: Replace SIGNAL and SLOT macros in aja-/decklink-output-ui 2023-07-21 13:19:52 +02:00
gxalpha 34f871e605
UI: Replace SIGNAL and SLOT macros in frontend-tools 2023-07-21 13:19:52 +02:00
gxalpha 0513e848d9
UI: Replace SIGNAL and SLOT macros in settings 2023-07-21 13:19:52 +02:00
gxalpha a0ef6e1baa
UI: Replace SIGNAL and SLOT macros in importer 2023-07-21 13:19:52 +02:00
gxalpha f7a7c652ab
UI: Replace SIGNAL and SLOT macros in filters 2023-07-21 13:19:52 +02:00
gxalpha d97d3a1871
UI: Replace SIGNAL and SLOT macros in window-basic-main 2023-07-21 13:19:50 +02:00
gxalpha e22ba27f2a
UI: Replace SIGNAL and SLOT macros in auto-config 2023-07-21 13:16:04 +02:00
gxalpha d5447fb2e5
UI: Replace SIGNAL and SLOT macros in transitions 2023-07-21 13:16:04 +02:00
gxalpha 24c97ed31b
UI: Replace SIGNAL and SLOT macros in about dialog 2023-07-21 13:16:04 +02:00
gxalpha e8147a9abb
UI: Replace SIGNAL and SLOT macros in properties-view 2023-07-21 13:16:04 +02:00
gxalpha e467f17501
UI: Replace SIGNAL and SLOT macros in obs-app 2023-07-21 13:16:04 +02:00
gxalpha 7f5fe30e36
UI: Replace SIGNAL and SLOT macros in remux
Also removes a GCC 4.8-workaround that should have been solved using
.data() on the QPointer instead of using a temporary variable.
2023-07-21 13:16:04 +02:00
gxalpha c4d2d98720
UI: Replace SIGNAL and SLOT macros in projectors 2023-07-21 13:16:04 +02:00
gxalpha cddb9dae45
UI: Replace SIGNAL and SLOT macros in missing files 2023-07-21 13:16:04 +02:00
gxalpha 43c692d386
UI: Replace SIGNAL and SLOT macros in media controls 2023-07-21 13:16:04 +02:00
gxalpha ac170a2d83
UI: Replace SIGNAL and SLOT macros in custom widgets 2023-07-21 13:16:04 +02:00
gxalpha fc07e59754
UI: Replace SIGNAL and SLOT macros in auth 2023-07-21 13:16:04 +02:00
gxalpha c1be5827c0
UI: Replace SIGNAL and SLOT macros in adv-audio-control 2023-07-21 13:16:03 +02:00
Richard Stanway b7fddceb67
updater: Treat mapped file errors as a sharing violation
For whatever reason there exists a different error code if the file has
been opened as a mapped file, so we need to handle it.
2023-07-21 03:02:31 +02:00
cg2121 cb8b5ba9cd libobs: Change return type for getting filter index
This changes the return type for getting the filter index from a
size_t to an int. This makes it easier for developers to use,
as an invalid index just returns a -1.
2023-07-20 13:21:14 -07:00
cg2121 1c84071830 UI: Redesign status bar
This redesigns the status bar to look more modern.

Co-authored-by: Warchamp7 <warchamp2003@hotmail.com>
Co-authored-by: Georges Basile Stavracas Neto <georges.stavracas@gmail.com>
2023-07-19 17:53:57 -07:00
gxalpha 9d611a064f cmake: Remove Qt version selection and Qt 5 support 2023-07-19 11:56:54 -04:00
gxalpha 79ab526f03 UI: Remove remaining Qt 6 ifdef 2023-07-19 11:56:54 -04:00
gxalpha 6a6cb3edcd UI: Avoid QT_TO_UTF8(QTStr()) double conversion 2023-07-18 15:07:25 -04:00
cg2121 04629afe68 UI: Adjust size policy for properties view
Now the properties won't be squished when making the properties
dialog smaller.
2023-07-17 17:46:46 -03:00
PatTheMav 902843634c
CI: Add new build and packaging scripts for macOS 2023-07-17 19:49:18 +02:00
cg2121 c33fa8bfa2 UI: Fix transform shortcuts for audio only sources
The edit, copy, paste and reset transform shortcuts would still work
for audio only sources, even though the menu was hidden for these.
2023-07-17 10:22:04 -07:00
Richard Stanway d997a56fb6 UI: Destroy the frontend API after OBS_FRONTEND_EVENT_EXIT
The frontend API was never explicitly cleaned up which has lead to
several crashes from plugins continuing to call it even after OBS itself
has been destroyed. We now destroy the API after the exit event, so
further calls by plugins will be no-ops instead of potentially accessing
destroyed OBS state.

This also required some changes to our own use of the API, as we relied
on the OBSBasic destructor to clean up some callbacks, by which point
the API should have already been destroyed.
2023-07-15 16:54:51 -07:00
gxalpha 84f1e962a1 UI: Don't set fragmentation movflags in lossless mode 2023-07-15 16:36:35 -07:00
gxalpha f7d5d80b04 UI: Localize font picker window title 2023-07-15 16:20:04 -07:00
derrod 593664dcdb clang-format: Set AllowShortLambdasOnASingleLine to Inline 2023-07-15 16:14:55 -07:00
derrod dcc07cfe4e clang-format: Set AllowAllConstructorInitializersOnNextLine to false 2023-07-15 16:14:55 -07:00
Benjamin Schubert 2fbc0dabda UI: Don't call activateWindow() when hidden 2023-07-15 16:11:27 -07:00
Clayton Groeneveld e121ac1587 UI, libobs: Add RAII wrappers for faders/volume meters
They can now be automatically deleted.
2023-07-15 16:06:36 -07:00
Kurt Kartaltepe 425be04014 UI: Disable QSV for simple mode on Linux
Linux QSV drivers have varying capabilities depending on if the
free/non-free Intel drivers are installed. This means we cannot safely
expose QSV in simple mode as users may be unable stream without changing
to advanced mode.
2023-07-14 12:19:33 -04:00
gxalpha a4834efde9 UI: Remove Qt 5 ifdef guards and code 2023-07-12 13:22:13 -04:00
Norihiro Kamae 39d4b53f6b UI: Fix preprocessor directives for platform integrations
The macros `YOUTUBE_ENABLED`, `RESTREAM_ENABLED`, and `TWITCH_ENABLED`
are not defined when the associated features are not enabled.
When the code was originally implemented, there were definitions to set
`0` if the feature is disabled. However a later commit 349372b removes
the definition. Now, the use of `#ifdef` is better than just `#if`.
2023-07-12 11:09:36 -04:00
derrod ad5f04e53d UI: Soft-delete scene collections
Instead of actually removing the file, simply rename it to the .bak
version which OBS ignores in most cases. That allows users to recover
accidentally deleted collections more easily, while only taking up a
few kilobytes of disk space at most.
2023-07-08 16:39:03 -07:00
Yoshimasa Niwa 9ab5271d69 UI: Fix crash radio list without items
Check items count before accessing first item,
or it will crash due to out-of-bound access.
2023-07-08 16:08:21 -07:00
Norihiro Kamae 65e35bec7d UI: Fix scenes only multiview label position 2023-07-07 16:38:52 -07:00
derrod 46525f5175 updater: Fix updating without patch files 2023-07-07 12:50:02 -04:00
Lain cececf4e55 UI: Wait for full vcam deactivation to destroy its view
A bug which was technically introduced in df446c3f6e: the author
assigned video mixes to the virtual camera and did not realize you have
to wait for full capture stop with the "deactivate" signal rather than
the "stop" signal. This situation is understandable because these
signals are likely confusing and need more documentation.

The way an output works when it stops is it has three stages:
- "stopping", which is the moment the user themselves stop the output
- "stop", when the output's implementation has stopped and returns
  success or an error code
- "deactivate", when the output inself (not the implementation) has
  fully stopped capturing encoded or raw frame data after the
  implementation has stopped. This is done in a separate thread,
  end_data_capture_thread(), for performance and data race reasons, and
  is when it's "actually fully stopped for real this time"

(Lain note: I sincerely apologize for this confusing signal design)

The author of df446c3f6e was likely confused as to why they could not
destroy the video mix in the "stop" signal without triggering a race
condition in end_data_capture_thread(), and instead decided to make a
workaround to clear the video mix set to the output before destroying
the video mix. Unsetting the video mix I'm guessing *seemed* to fix the
problem for them at the time, and destroying the video mix separately
after that automatically stops capture, so it *technically* worked
because the deactivate thread cannot be called until the
implementation's stop signal has executed. However, it was still the
incorrect way to handle the problem, because it circumvents the output's
mechanism for deactivating the frame data capture by destroying the view
instead.

The reason this was the incorrect way to handle the problem became
exposed in 7cd7ca80f8, when tytan made it so it uses the main video mix
under certain circumstances. The main view is special and cannot be
destroyed, so the mechanism to stop frame data capture that the
virtualcam was using before failed, and raw frame data capture continued
perpetually until the end of the program erroneously.

This fix solves the bug by using the "deactivate" signal rather than the
"stop" signal, thus allowing the output to fully end its data capture
and *then* destroy the video mix.

Fixes obsproject/obs-studio#9153
2023-07-06 15:37:28 -07:00
derrod 7773ea0180 UI: Fix utf-8 paths in shared updater components 2023-07-02 05:09:17 +02:00
Penwywern 0a610dcc7a UI: Add logging of Program scene changes in studio mode 2023-06-30 14:14:31 -07:00
PatTheMav c586c1d06f cmake: Add support for unobfuscated OAuth secrets
Unobfuscated secrets require the hash values to be set to 0, by default
CMake will treat 0 as a falsy value. This commit adds support for
_either_ 0 _or_ a valid hexadecimal hash.
2023-06-30 12:22:42 -04:00
PatTheMav db895092ed cmake: Add changes for CMake build framework 3.0
New code path only taken if OBS_CMAKE_VERSION is set to 3.0.0 or
greater, old functionality remains unchanged.
2023-06-29 10:11:32 -04:00
derrod 67f7712d83 UI: Migrate undo/redo to using UUIDs 2023-06-28 11:04:56 -07:00
pkv 457c88b138 UI: Change surround sound warning to signal YouTube support
YouTube Live now supports 5.1 surround sound.
The surround sound warning in Settings has been updated to reflect that.

Signed-off-by: pkv <pkv@obsproject.com>
2023-06-24 17:11:01 -07:00
cg2121 80f43998e6 UI: Fix icon paths of transition buttons
In Qt Creator, the transition add/remove buttons had no icons,
as the paths were incorrect.
2023-06-25 09:25:36 +10:00
Clayton Groeneveld f2f4582141 UI: Add ability to reorder filters by drag & drop
This adds the ability for filters to be dragged and dropped
to be reordered, similar to scenes and sources.
2023-06-21 15:33:48 -07:00
cg2121 e863bea7fb UI: Add QDataStream opreators for OBSSource
Allows serializing/deserializing sources in and out of QDataStreams via
their UUID
2023-06-21 15:33:48 -07:00
gxalpha a35e5aae41 UI: Disable Ok button in Add Source dialog if no source is selected 2023-06-17 16:46:05 -07:00
Norihiro Kamae bff468d7ec UI: Reuse StudioMode.Preview translation for virtual camera config 2023-06-17 16:43:44 -07:00
Norihiro Kamae 323f3957cd UI: Translate place holder name for new group 2023-06-17 16:42:53 -07:00
Norihiro Kamae 846cdafbed UI: Fix changed state of audio settings
When changing audio channels, sample rate, or audio buffering settings
multiple times by hitting `Apply` button, the internal `changed` state
got corrupted. To avoid this, set the changed state when changed
something, but do not clear the changed state.
2023-06-17 16:42:14 -07:00
Norihiro Kamae 35463cb464 UI: Fix changing quick transition to/from fade to black 2023-06-17 16:39:27 -07:00
Norihiro Kamae a1c88d58fc UI: Fix checked state of source toolbar menu item
After the source toolbar was hidden or shown by a hotkey, the checked
state of the menu item was not updated.
2023-06-17 16:36:59 -07:00
gxalpha 1933579b9c UI: Capitalize "Full-Height Docks" 2023-06-17 16:28:59 -07:00
PatTheMav 59904a66a3 cmake: Update Framework link definition for macOS builds 2023-06-17 12:23:33 -04:00
PatTheMav 50a4e83251 cmake: Remove Info.plist template files for macOS builds
Creation of Info.plist files through Xcode is more canonical and
future-proof, as it will automatically pick up changes/updates
introduced by Apple. Non-standard keys can still be added via a
template file, which will then be extended by Xcode with the default
keys.
2023-06-17 12:23:33 -04:00
PatTheMav 9f0a2547ac UI: Fix preventing copy elision of a temporary string object 2023-06-16 14:12:58 -04:00
PatTheMav 343055c889 UI: Wrap unreachable code in comment to fix clang warnings
The branch is never taken and the code acts as documentation for a
(possible) future use case. According to YAGNI it could be removed
entirely, wrapping it in a comment is the less destructive approach.
2023-06-16 14:12:58 -04:00
PatTheMav 5ca17aa25f UI: Disable warnings emitted by Qt frameworks
Qt uses quoted includes in Framework headers (which is discouraged
by Apple) and also has some questionable use of the comma operator.
2023-06-16 14:12:58 -04:00
Colin Edwards d31d271b43 UI: Move WHIP service to the bottom of the visible list 2023-06-15 12:38:11 -04:00
PatTheMav f8e00d6071 clang-format: Update formatting of all ObjC and ObjC++ files 2023-06-11 14:56:45 +02:00
cg2121 45e895206d UI: Render preview lines above safe areas
Moves the preview lines around sources to be rendered above the
preview safe area lines.
2023-06-10 17:35:57 -07:00
derrod 66b3a04424 UI: Assume RTMP if service has no protocol
(cherry picked from commit e26a04fa44)
2023-06-11 02:18:17 +02:00
derrod 8983083cec updater: Refactor and cleanup 2023-06-11 02:17:28 +02:00
derrod ef3a67708e UI: Support PCM in MP4 2023-06-10 17:10:30 -07:00
Colin Edwards 353a4c860d UI: Don't show WHIP in stream settings if the protocol isn't registered 2023-06-10 16:50:55 -07:00
Exeldro e830043851 UI: Don't update text source when nothing changed 2023-06-10 16:45:42 -07:00
gxalpha fe2eee951b UI: Don't create combobox for radio buttons in properties view 2023-06-10 16:13:57 -07:00
cg2121 5cc319d97f UI: Change name of ResetProxyStyleSliders function
Changes the name to ThemeChanged, as the function now does more than
reset the volume sliders.
2023-06-10 16:06:16 -07:00
Sean DuBois dd392188b8 UI: Enable WHIP service in UI
This provides the UI glue to enable the WHIP service introduced in the
obs-webrtc plugin.

Co-authored-by: John Bradley <jocbrad@twitch.tv>
Signed-off-by: pkv <pkv@obsproject.com>
2023-06-09 20:20:49 -05: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
tududweb 4871fd301a UI: Don't trigger a settings update when list is empty
To avoid recursive call
2023-06-07 12:50:48 -07:00
tytan652 90d96e92c2 obs-frontend-api,UI,docs: Add API to add custom docks with no toggle
Some plugin does that by deleting the QAction returned by
obs_frontend_add_dock().

Now that obs_frontend_add_dock() is deprecated,
obs_frontend_add_custom_qdock() replace this usage.
2023-06-03 16:47:01 -07:00
tytan652 cde5545f8f obs-frontend-api,UI,docs: Add dock API that ask for unique object name
obs_frontend_add_dock() is deprecated in favor of
obs_frontend_add_dock_by_id()
2023-06-03 16:47:01 -07:00
tytan652 f2fa54120a UI: Avoid having two dock with the same object name
https://doc.qt.io/qt-6/qmainwindow.html#saveState

You should make sure that this property is unique for each QToolBar and
QDockWidget you add to the QMainWindow.
2023-06-03 16:47:01 -07:00
Igor Bochkariov df3b294fc3 UI: allow side docks to be tall
before: widgets docked on the sides of the preview are of the height of
the preview

after: the user can toggle the setting in the docks menu so the side
widgets are of the height of the whole window

UI: change menu label to Full-height docks
2023-06-04 09:39:47 +10:00
cg2121 382edcebb7 UI: Also toggle mixer toolbar in view menu
This change makes the mixer toolbar also show/hide when toggling
the source toolbars in the view menu.
2023-06-03 16:03:37 -07:00
gxalpha b69ee759d2 UI: Sort encoders alphabetically 2023-06-03 13:48:47 -07:00
cg2121 4c9e1949ad UI: Fix filter shortcuts not showing in context menu
This fixes the shortcuts not showing up in the filters context
menu for rename and remove. This also has a code cleanup for
the rename action, as now it is created in the ui file.
2023-06-03 11:53:36 -07:00
tytan652 7cd7ca80f8 UI: Use main video on the virtual camera if program
This change allows the virtual camera to really output what is in the
program view, some plugin interract with this view but their changes
does not appear on the virtual camera.
2023-05-30 16:16:07 -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
cg2121 016ce128b7 UI: Fix menu actions missing shortcuts
The scene and source rename/remove actions were missing shortcuts
in the context menu.
2023-05-27 16:26:02 -07:00
Norihiro Kamae b21edafe98 UI: Fix crash on patronJsonThread
If a user exit obs while patronJsonThread is running, the thread crashed
with the error below.
  QThread: Destroyed while thread is still running
2023-05-26 12:54:33 -04:00
gxalpha adb7029298 UI: Don't use ellipses in permissions window title 2023-05-24 15:47:10 -04:00
gxalpha 4b37692939 UI: Disallow exiting settings with no track in advanced mode 2023-05-24 12:30:27 -04:00
gxalpha 2bc368349f UI: Disallow exiting settings with no track in simple mode 2023-05-24 12:30:27 -04: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
cg2121 fc8c428521 UI: Move saving of scene tree grid mode
Widget shouldn't save their own states, as then they can't be used
elsewhere.
2023-05-21 01:48:13 -07:00
cg2121 20896280b1 UI: Fix compiling error on Ubuntu
Makes sure ceil function uses std namespace
2023-05-21 01:48:13 -07:00
cg2121 3a53882675 UI: Add scene grid mode to view menu
Makes toggling of the scene list grid mode also available in the
view menu.
2023-05-20 17:06:18 -07:00
gxalpha 58fb63030c UI: Only defer property updates for input and transition sources
Deferring properties was only ever made for input and transition
sources. As other property dialogs do not have an "Ok" button that would
cause an update to happen, if the deferred flag was set the callback
would never be called.
Also clarifies the docs to reflect this.
2023-05-20 16:55:50 -07:00
PatTheMav ccedbc0218 UI: Update display capture toolbar dropdown to use uuid field 2023-05-20 16:50:16 -07:00
gxalpha ad9fd6c6f0 libobs,UI: Add properties radio button list 2023-05-20 16:48:23 -07:00
gxalpha f049962bb2 libobs: Add properties list boolean format 2023-05-20 16:48:23 -07:00
Norihiro Kamae c335219582 UI: Fix missing translations
This commit fixes a typo in a translation key, adds two missing
translations, and also removes obsolete translations in the translation
files.
2023-05-20 16:27:28 -07:00
Lain 106c7aa61f Update copyrights/names 2023-05-20 01:31:18 -07:00
Jim fcfc2eb5fc UI: Fix 0,0 size transform bug when resizing sources
Fix a bug where if a source's width or height becomes 0 while you're
stretching the size of a source or modifying it from the transform
dialog, it would become permanently invisible

Closes obsproject/obs-studio#7962
2023-05-19 17:31:14 -07:00