Move clang-format, update deps

This commit is contained in:
Martin Rotter 2023-12-21 14:43:59 +01:00
parent 1a4123cd54
commit 5a10a24a19
5 changed files with 13 additions and 16 deletions

View File

@ -40,7 +40,7 @@ $maria_version = "11.2.2"
$maria_link = "https://archive.mariadb.org/mariadb-$maria_version/winx64-packages/mariadb-$maria_version-winx64.zip"
$maria_output = "maria.zip"
$cmake_version = "3.27.9"
$cmake_version = "3.28.1"
$cmake_link = "https://github.com/Kitware/CMake/releases/download/v$cmake_version/cmake-$cmake_version-windows-x86_64.zip"
$cmake_output = "cmake.zip"
@ -48,7 +48,7 @@ $zlib_version = "1.3"
$zlib_link = "https://github.com/madler/zlib/archive/refs/tags/v$zlib_version.zip"
$zlib_output = "zlib.zip"
$libmpv_version = "20231211-git-566a96f"
$libmpv_version = "20231220-git-17be6e1"
$libmpv_link = "https://github.com/zhongfly/mpv-winbuild/releases/download/2023-12-11-566a96f/mpv-dev-x86_64-$libmpv_version.7z"
$libmpv_output = "mpv.zip"

View File

@ -590,8 +590,7 @@ void FormMessageFiltersManager::beautifyScript() {
proc_clang_format.setArguments({"--assume-filename=script.js", "--style=Chromium"});
#if defined(Q_OS_WIN)
proc_clang_format.setProgram(qApp->applicationDirPath() + QDir::separator() + QSL("clang-format") +
QDir::separator() + QSL("clang-format.exe"));
proc_clang_format.setProgram(qApp->applicationDirPath() + QDir::separator() + QSL("clang-format.exe"));
#else
proc_clang_format.setProgram(QSL("clang-format"));
#endif

View File

@ -23,7 +23,7 @@ LibMpvWidget::LibMpvWidget(mpv_handle* mpv_handle, QWidget* parent)
: BASE_WIDGET(parent), m_mpvHandle(mpv_handle)
#if defined(MEDIAPLAYER_LIBMPV_OPENGL)
,
m_mpvGl(nullptr)
m_mpvGL(nullptr)
#endif
{
#if !defined(MEDIAPLAYER_LIBMPV_OPENGL)
@ -60,9 +60,9 @@ void LibMpvWidget::destroyHandle() {
#if defined(MEDIAPLAYER_LIBMPV_OPENGL)
makeCurrent();
if (m_mpvGl != nullptr) {
mpv_render_context_free(m_mpvGl);
m_mpvGl = nullptr;
if (m_mpvGL != nullptr) {
mpv_render_context_free(m_mpvGL);
m_mpvGL = nullptr;
}
doneCurrent();
@ -126,11 +126,11 @@ void LibMpvWidget::initializeGL() {
display,
{MPV_RENDER_PARAM_INVALID, nullptr}};
if (mpv_render_context_create(&m_mpvGl, m_mpvHandle, params) < 0) {
if (mpv_render_context_create(&m_mpvGL, m_mpvHandle, params) < 0) {
qFatal("failed to initialize mpv GL context");
}
mpv_render_context_set_update_callback(m_mpvGl, LibMpvWidget::onMpvRedraw, reinterpret_cast<void*>(this));
mpv_render_context_set_update_callback(m_mpvGL, LibMpvWidget::onMpvRedraw, reinterpret_cast<void*>(this));
}
void LibMpvWidget::paintGL() {
@ -140,8 +140,7 @@ void LibMpvWidget::paintGL() {
mpv_render_param params[] = {{MPV_RENDER_PARAM_OPENGL_FBO, &mpfbo},
{MPV_RENDER_PARAM_FLIP_Y, &flip_y},
{MPV_RENDER_PARAM_INVALID, nullptr}};
// See render_gl.h on what OpenGL environment mpv expects, and
// other API details.
mpv_render_context_render(m_mpvGl, params);
mpv_render_context_render(m_mpvGL, params);
}
#endif

View File

@ -46,7 +46,7 @@ class LibMpvWidget : public BASE_WIDGET {
private:
static void onMpvRedraw(void* ctx);
mpv_render_context* m_mpvGl;
mpv_render_context* m_mpvGL;
#endif
};

View File

@ -50,9 +50,8 @@ if(WIN32)
DESTINATION .
FILES_MATCHING PATTERN "*.dll"
)
install(DIRECTORY ${CMAKE_SOURCE_DIR}/resources/scripts/clang-format
install(FILES ${CMAKE_SOURCE_DIR}/resources/scripts/clang-format/clang-format.exe
DESTINATION .
FILES_MATCHING PATTERN "*.exe"
)
elseif(OS2)
install(TARGETS app DESTINATION .)