Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/frameworks/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ target_sources(openboard PRIVATE
UBVersion.h
)

if(CMAKE_SYSTEM_NAME STREQUAL Linux)
if(CMAKE_SYSTEM_NAME MATCHES "FreeBSD|Linux")
target_sources(openboard PRIVATE
UBPlatformUtils_linux.cpp
)
Expand Down
15 changes: 11 additions & 4 deletions src/frameworks/UBPlatformUtils_linux.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,9 @@
#include "core/UBSettings.h"
#include "gui/UBMainWindow.h"

#ifndef Q_OS_FREEBSD
static OnboardListener* listener = nullptr;
#endif

void UBPlatformUtils::init()
{
Expand Down Expand Up @@ -94,15 +96,15 @@ QString UBPlatformUtils::applicationTemplateDirectory()
void UBPlatformUtils::hideFile(const QString &filePath)
{
Q_UNUSED(filePath)
// TODO UB 4.x Not possible on Linux as such, the filename should have a . as first char in name
// TODO UB 4.x Not possible on FreeBSD and Linux as such, the filename should have a . as first char in name
}

void UBPlatformUtils::setFileType(const QString &filePath, unsigned long fileType)
{
Q_UNUSED(filePath)
Q_UNUSED(fileType)

// No fileType equivalent on Linux
// No fileType equivalent on FreeBSD and Linux
}

void UBPlatformUtils::fadeDisplayOut()
Expand Down Expand Up @@ -478,14 +480,14 @@ QString UBPlatformUtils::urlFromClipboard()
{
QString qsRet;

// Not used on Linux
// Not used on FreeBSD and Linux

return qsRet;
}

void UBPlatformUtils::setFrontProcess()
{
// not used in Linux
// not used in FreeBSD and Linux
}


Expand All @@ -501,6 +503,10 @@ void UBPlatformUtils::showFullScreen(QWidget *pWidget)

void UBPlatformUtils::showOSK(bool show)
{
#ifdef Q_OS_FREEBSD
Q_UNUSED(show);
// No on-screen keyboard support on FreeBSD
#else
if (show)
{
QDBusInterface dbus("org.onboard.Onboard", "/org/onboard/Onboard/Keyboard");
Expand Down Expand Up @@ -562,4 +568,5 @@ void OnboardListener::onboardPropertiesChanged(QString interface, QMap<QString,
oskAction->trigger();
}
}
#endif
}
2 changes: 1 addition & 1 deletion src/gui/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ target_sources(${PROJECT_NAME} PRIVATE
UBZoomPalette.h
)

if(CMAKE_SYSTEM_NAME STREQUAL Linux)
if(CMAKE_SYSTEM_NAME MATCHES "FreeBSD|Linux")
target_sources(openboard PRIVATE
UBKeyboardPalette_linux.cpp
)
Expand Down
6 changes: 3 additions & 3 deletions src/podcast/UBPodcastController.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@
#elif defined(Q_OS_OSX)
#include "ffmpeg/UBFFmpegVideoEncoder.h"
#include "ffmpeg/UBMicrophoneInput.h"
#elif defined(Q_OS_LINUX)
#elif defined(Q_OS_LINUX) || defined(Q_OS_FREEBSD)
#include "ffmpeg/UBFFmpegVideoEncoder.h"
#include "ffmpeg/UBMicrophoneInput.h"
#endif
Expand Down Expand Up @@ -315,7 +315,7 @@ void UBPodcastController::start()
mVideoEncoder = new UBWindowsMediaVideoEncoder(this); //deleted on stop
#elif defined(Q_OS_OSX)
mVideoEncoder = new UBFFmpegVideoEncoder(this);
#elif defined(Q_OS_LINUX)
#elif defined(Q_OS_LINUX) || defined(Q_OS_FREEBSD)
mVideoEncoder = new UBFFmpegVideoEncoder(this);
#endif

Expand Down Expand Up @@ -780,7 +780,7 @@ QStringList UBPodcastController::audioRecordingDevices()
devices = UBWaveRecorder::waveInDevices();
#elif defined(Q_OS_OSX)
devices = UBMicrophoneInput::availableDevicesNames();
#elif defined(Q_OS_LINUX)
#elif defined(Q_OS_LINUX) || defined(Q_OS_FREEBSD)
devices = UBMicrophoneInput::availableDevicesNames();
#endif

Expand Down
2 changes: 1 addition & 1 deletion src/web/UBEmbedController.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -150,7 +150,7 @@ void UBEmbedController::textChanged(const QString& newText)
static const QRegularExpression regExp("[<>:\"/\\\\|?*]");
#endif

#ifdef Q_OS_LINUX // Defined on X11.
#if defined(Q_OS_LINUX) || defined(Q_OS_FREEBSD) // Defined on X11.
QString illegalCharList(" < > : \" / \\ | ? * ");
static const QRegularExpression regExp("[<>:\"/\\\\|?*]");
#endif
Expand Down