Commit graph

325 commits

Author SHA1 Message Date
tytan652 511385891c UI: Separate controls dock from the main window 2024-06-05 17:39:54 -04:00
tytan652 d23b65a2bf UI: Track streaming state in OBSBasic
Avoid using controls dock buttons for streaming state. Use signals and
OBSBasic member variables instead.
2024-06-05 17:39:54 -04:00
tytan652 9093275336 UI: Track recording state in OBSBasic
Avoid using controls dock buttons for recording states. Use signals and
OBSBasic member variables instead.
2024-06-05 17:39:54 -04:00
tytan652 cb024a0696 UI: Use connection with modeSwitch button 2024-06-05 17:39:54 -04:00
Ruwen Hahn c8950900c3 UI: Add eRTMP Multitrack Video Output 2024-06-04 20:50:46 -04:00
Lain f71a67cd3a
Merge pull request #10608 from derrod/obs-mp4-muxer
Native Hybrid MP4 Muxer
2024-05-28 21:55:58 -07:00
Tunghohin 51fd7fbaff UI: Removed unused friend classes 2024-05-28 15:04:05 -04:00
derrod 8ac8118b7f UI: Add chapter frontend API and hotkey 2024-05-26 23:11:48 +02:00
gxalpha 4cf18a9abf UI: Add undo/redo to Paste Filters on audio mixer and scenes
Copy-Pasting filters on a scene or on a source via the audio mixer
context menu would not add an undo/redo action. This commit factors the
undo/redo logic out into a generic paste filters function that can be
used for pasting filters everywhere.
2024-05-25 17:06:21 -07:00
gxalpha 8184fa10a3 UI: Inline OBSBasic::ThemeChanged()
The majority of this method got removed in a prior commit [1]. Let's
inline the rest.

[1] 8dcfae9a39
2024-05-25 17:04:58 -07:00
Warchamp7 ac160c906d UI: Include duration when copy/pasting scene item transitions 2024-04-13 16:44:51 -07:00
derrod 31aa700d22 UI: Always retain collection data of unloaded modules 2024-04-13 16:06:28 -07:00
Ryan Foster 11131682b1 UI: Check low disk space only if recording to a file
The Custom FFmpeg Output allows the user to configure it to output to a
URL instead of a file. In OBSBasic::StartRecording(), we unconditionally
call LowDiskSpace() to check for low disk space because we assume that a
"recording" will always be to disk. When os_get_free_disk_space() is
called on a non-existent path, it returns 0, which causes OBS to emit a
low disk space warning. Instead, only call DiskSpaceMessage() if not
"recording" to a URL.
2024-03-30 16:24:04 -07:00
cg2121 140abfeb66 UI: Fix closing OBS with floating docks
When OBS is closed and there is a floating dock, a Windows system
sound is emitted. This fixes that by not executing the close dock
dialog when OBS is closing.
2024-03-11 20:38:04 -04:00
derrod 32e201ebb9 UI: Save invalid transition source data in safe mode 2024-01-13 17:59:42 -06:00
derrod 46c00a95cd UI: Save last used output resolution to scene collection 2024-01-06 17:06:00 -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
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
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
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 b429d00440 UI: Show link to release notes in Help menu 2023-08-12 16:46:38 -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
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
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
derrod 396cfdb416 UI: Add Safe Mode 2023-07-21 23:22:07 +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 d97d3a1871
UI: Replace SIGNAL and SLOT macros in window-basic-main 2023-07-21 13:19:50 +02:00
gxalpha d5447fb2e5
UI: Replace SIGNAL and SLOT macros in transitions 2023-07-21 13:16:04 +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
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
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
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 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
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
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
Lain 106c7aa61f Update copyrights/names 2023-05-20 01:31:18 -07:00
derrod 4419786840 UI: Exit and show error if clearing scene data fails 2023-05-07 11:03:53 -07: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
derrod 09b6786f1a UI: Add Help menu action to show What's New dialog 2023-03-18 15:21:52 -07:00
tytan652 e6873d3278 UI: Refactor integration and browser docks
Use the QAction provided by QDockWidget with new Qt connection rather
than creating a new one for each dock.

Separate extra browser docks from extra docks, the latter is meant for
plugin/integration docks.
2023-03-17 20:21:08 +11:00
cg2121 03a94aee41 UI: Fix wrong program scene if tbar is aborted
The program scene would be incorrect if the tbar was released
at its original position.
2023-03-04 16:31:37 -08:00
tytan652 501a3e926d UI: Refactor Virtual Camera source selector dialog 2023-02-25 16:06:59 -08:00
gxalpha 8d4a0b3645 UI: Use valueChanged() signal for T-Bar everywhere
The sliderMoved signal doesn't trigger when clicking on the slider, only
the valueChanged signal. According to QTBUG-72995 this is intentional,
since the documentation states that sliderDown also needs to be true for
the sliderMoved signal to be triggered. As for why sliderDown isn't true
when clicking, or why that would even be necessary for a signal that
should trigger when the slider is moved (and it very clearly moves)
remains a mystery.

Also gets rid of the wrong usage of the on_foo_bar slot declaration,
which should only be used for signals where the sender is part of a UI
file and it gets connected automatically. While it of course is possible
to connect it manually, this is against convention and can cause
confusion. In this case it was particularly wrong since even if tBar was
part of a UI file (which it isn't), the method should have been called
on_tBar_valueChanged instead of on_tbar_position_valueChanged.
2023-02-20 19:10:32 +01:00
derrod 12a27d8b99 UI: Add update channels (macOS) 2023-02-19 01:35:56 +01:00
gxalpha 9afc3cabca UI: Refactor / Clean up addNudge 2023-02-15 14:11:46 -05:00
derrod 5bdf492f8a UI: Avoid excessive config reads when drawing preview 2023-02-11 15:58:40 -08:00
cg2121 26725fa2d5 UI: Disable properties button in source toolbar
If a scene or group is selected, disable the properties button in the
source toolbar. This also does a refactor of the function to enable/disable
the toolbar buttons.
2023-02-04 16:02:04 -08:00