Skip to content

Commit

Permalink
Merge branch 'stable-1.2'
Browse files Browse the repository at this point in the history
# Conflicts:
#	.travis.yml
#	CMakeLists.txt
#	src/core/Track.cpp
  • Loading branch information
PhysSong committed Jul 5, 2020
2 parents 84998a2 + 94363be commit c83c9bf
Show file tree
Hide file tree
Showing 7 changed files with 60 additions and 48 deletions.
14 changes: 0 additions & 14 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,17 +31,3 @@ script: ${TRAVIS_BUILD_DIR}/.travis/script.sh
after_script: ${TRAVIS_BUILD_DIR}/.travis/after_script.sh
before_deploy:
- if [ "$TARGET_OS" != debian-sid ]; then make package; fi
deploy:
provider: releases
api_key:
secure: d4a+x4Gugpss7JK2DcHjyBZDmEFFh4iVfKDfITSD50T6Mc6At4LMgojvEu+6qT6IyOY2vm3UVT6fhyeuWDTRDwW9tfFlaHVA0h8aTRD+eAXOA7pQ8rEMwQO3+WCKuKTfEqUkpL4wxhww8dpkv54tqeIs0S4TBqz9tk8UhzU7XbE=
file_glob: true
file:
- lmms-${TRAVIS_TAG:1}-$TARGET_OS.exe
- /var/cache/pbuilder/result/lmms_*.tar.xz
skip_cleanup: true
on:
tags: true
all_branches: true
condition: '"$TARGET_DEPLOY" = True'
repo: LMMS/lmms
2 changes: 1 addition & 1 deletion .travis/script.sh
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ if [ "$TYPE" = 'style' ]; then

else

export CMAKE_FLAGS="-DCMAKE_BUILD_TYPE=RelWithDebInfo"
export CMAKE_FLAGS="-DCMAKE_BUILD_TYPE=RelWithDebInfo -DBUNDLE_QT_TRANSLATIONS=ON"

if [ -z "$TRAVIS_TAG" ]; then
export CMAKE_FLAGS="$CMAKE_FLAGS -DUSE_CCACHE=ON"
Expand Down
17 changes: 15 additions & 2 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ INCLUDE(GenerateExportHeader)

STRING(TOUPPER "${CMAKE_PROJECT_NAME}" PROJECT_NAME_UCASE)

SET(PROJECT_YEAR 2019)
SET(PROJECT_YEAR 2020)

SET(PROJECT_AUTHOR "LMMS Developers")
SET(PROJECT_URL "https://lmms.io")
Expand All @@ -36,7 +36,7 @@ SET(PROJECT_DESCRIPTION "${PROJECT_NAME_UCASE} - Free music production software"
SET(PROJECT_COPYRIGHT "2008-${PROJECT_YEAR} ${PROJECT_AUTHOR}")
SET(VERSION_MAJOR "1")
SET(VERSION_MINOR "2")
SET(VERSION_RELEASE "1")
SET(VERSION_RELEASE "2")
SET(VERSION_STAGE "")
SET(VERSION_BUILD "0")
SET(VERSION "${VERSION_MAJOR}.${VERSION_MINOR}.${VERSION_RELEASE}")
Expand Down Expand Up @@ -77,6 +77,7 @@ OPTION(WANT_VST_32 "Include 32-bit VST support" ON)
OPTION(WANT_VST_64 "Include 64-bit VST support" ON)
OPTION(WANT_WINMM "Include WinMM MIDI support" OFF)
OPTION(WANT_DEBUG_FPE "Debug floating point exceptions" OFF)
OPTION(BUNDLE_QT_TRANSLATIONS "Install Qt translation files for LMMS" OFF)


IF(LMMS_BUILD_APPLE)
Expand All @@ -101,6 +102,7 @@ IF(LMMS_BUILD_WIN32)
SET(WANT_SNDIO OFF)
SET(WANT_SOUNDIO OFF)
SET(WANT_WINMM ON)
SET(BUNDLE_QT_TRANSLATIONS ON)
SET(LMMS_HAVE_WINMM TRUE)
SET(STATUS_ALSA "<not supported on this platform>")
SET(STATUS_JACK "<not supported on this platform>")
Expand Down Expand Up @@ -171,6 +173,17 @@ ENDIF()
# Resolve Qt5::qmake to full path for use in packaging scripts
GET_TARGET_PROPERTY(QT_QMAKE_EXECUTABLE "${Qt5Core_QMAKE_EXECUTABLE}" IMPORTED_LOCATION)

# Find the location of Qt translation files
execute_process(COMMAND ${QT_QMAKE_EXECUTABLE} -query QT_INSTALL_TRANSLATIONS
OUTPUT_VARIABLE QT_TRANSLATIONS_DIR
OUTPUT_STRIP_TRAILING_WHITESPACE
ERROR_QUIET
)
IF(EXISTS "${QT_TRANSLATIONS_DIR}")
MESSAGE("-- Found Qt translations in ${QT_TRANSLATIONS_DIR}")
ADD_DEFINITIONS(-D'QT_TRANSLATIONS_DIR="${QT_TRANSLATIONS_DIR}"')
ENDIF()

FIND_PACKAGE(Qt5Test)
SET(QT_QTTEST_LIBRARY Qt5::Test)

Expand Down
6 changes: 3 additions & 3 deletions data/locale/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -47,9 +47,9 @@ FOREACH(_item ${qm_targets})
ADD_DEPENDENCIES(finalize-locales "${_item}")
ENDFOREACH(_item ${qm_targets})

IF(LMMS_BUILD_WIN32)
FILE(GLOB QT_QM_FILES "${QT_TRANSLATIONS_DIR}/qt*[^h].qm")
IF(BUNDLE_QT_TRANSLATIONS)
FILE(GLOB QT_QM_FILES "${QT_TRANSLATIONS_DIR}/qt*.qm")
LIST(SORT QT_QM_FILES)
ENDIF(LMMS_BUILD_WIN32)
ENDIF()

INSTALL(FILES ${QM_FILES} ${QT_QM_FILES} DESTINATION "${LMMS_DATA_DIR}/locale")
42 changes: 28 additions & 14 deletions doc/CONTRIBUTORS
Original file line number Diff line number Diff line change
Expand Up @@ -9,24 +9,26 @@ Colin Wallace <[email protected]>
Oskar Wallgren <[email protected]>
Raine M. Ekman <[email protected]>
Umcaruje <[email protected]>
Michael Gregorius <[email protected]>
Hyunjin Song <[email protected]>
Javier Serrano Polo <[email protected]>
Michael Gregorius <[email protected]>
grejppi <[email protected]>
Javier Serrano Polo <[email protected]>
Hyunjin Song <[email protected]>
Wong Cho Ching <[email protected]>
Alexandre Almeida <[email protected]>
Daniel Winzen <[email protected]>
LMMS Service Account <[email protected]>
Steffen Baranowsky <[email protected]>
Danny McRae <[email protected]>
Johannes Lorenz <[email protected]>
Garrett <[email protected]>
Hyunin Song <[email protected]>
liushuyu <[email protected]>
Dominic Clark <[email protected]>
Hyunin Song <[email protected]>
Andrew Kelley <[email protected]>
Spekular <[email protected]>
Andreas Brandmaier <[email protected]>
Fastigium <[email protected]>
Spekular <[email protected]>
Amadeus Folego <[email protected]>
Jonas Trappenberg <[email protected]>
M374LX <[email protected]>
Expand All @@ -35,18 +37,17 @@ grindhold <[email protected]>
Mike Choi <[email protected]>
Karmo Rosental <[email protected]>
Christopher L. Simons <[email protected]>
Dominic Clark <[email protected]>
NoiseByNorthwest <[email protected]>
falkTX <[email protected]>
Johannes Lorenz <[email protected]>
Rebecca DeField <[email protected]>
falkTX <[email protected]>
Stian Jørgensrud <[email protected]>
David Carlier <[email protected]>
Ryan Roden-Corrent <[email protected]>
Shmuel H <[email protected]>
midi-pascal <[email protected]>
Augustin Cavalier <[email protected]>
BaraMGB <[email protected]>
Csaba Hruska <[email protected]>
David Carlier <[email protected]>
DeRobyJ <[email protected]>
Hussam Eddin Alhomsi <[email protected]>
Rüdiger Ranft <[email protected]>
Expand All @@ -66,11 +67,15 @@ Jonathan Aquilina <[email protected]>
Mohammad Amin Sameti <[email protected]>
ra <[email protected]>
wongcc966422 <[email protected]>
Cyp <[email protected]>
David CARLIER <[email protected]>
Douglas <[email protected]>
Gurjot Singh <[email protected]>
Janne Sinisalo <[email protected]>
Krzysztof Foltman <[email protected]>
Lou Herard <[email protected]>
Noah Brecht <[email protected]>
Olivier Humbert <[email protected]>
Paul Batchelor <[email protected]>
Paul Wayper <[email protected]>
Petter Reinholdtsen <[email protected]>
Expand All @@ -86,9 +91,8 @@ Cyrille Bollu <[email protected]>
Dan Williams <[email protected]>
Ian Sannar <[email protected]>
Jaroslav Petrnoušek <[email protected]>
Johannes Lorenz <[email protected]>
Johannes Lorenz <[email protected]>
Kenneth Perry (thothonegan) <[email protected]>
Kevin Zander <[email protected]>
LYF610400210 <[email protected]>
Lukas W <[email protected]>
Mark-Agent003 <[email protected]>
Expand All @@ -101,29 +105,37 @@ Rebecca LaVie <[email protected]>
Roberto Giaconia <[email protected]>
SecondFlight <[email protected]>
Steffen Baranowsky <[email protected]>
T0NIT0 RMX <[email protected]>
TheTravelingSpaceman <[email protected]>
Thomas Clark <[email protected]>
gnudles <[email protected]>
liushuyu <[email protected]>
makepost <[email protected]>
miketurn <[email protected]>
psyomn <[email protected]>
quadro <[email protected]>
sarahkeefe <[email protected]>
thmueller64 <[email protected]>
Achim Settelmeier <[email protected]>
Alexandra Dutton <[email protected]>
Andreas Müller <[email protected]>
André Hentschel <[email protected]>
Armin Kazmi <[email protected]>
Artur Twardowski <[email protected]>
Attila Herman <[email protected]>
Bastian Kummer <[email protected]>
Christopher A. Oliver <[email protected]>
Cyp <[email protected]>
Devin Venable <[email protected]>
Diego Ramos Ruggeri <[email protected]>
Douglas <[email protected]>
DragonEagle <[email protected]>
Filip Hron <[email protected]>
Frank Mather <[email protected]>
Frederik <[email protected]>
Gingka Akiyama <[email protected]>
Greg Simpson <[email protected]>
Hexasoft <[email protected]>
Hubert Figuière <[email protected]>
IvanMaldonado <[email protected]>
Ivo Wetzel <[email protected]>
Jens Lang <[email protected]>
Expand All @@ -138,17 +150,17 @@ Lee Avital <[email protected]>
LocoMatt <[email protected]>
Léo Andrès <[email protected]>
Markus Elfring <[email protected]>
Martin Pavelek <[email protected]>
Maurizio Lo Bosco <[email protected]>
Mehdi <[email protected]>
Mikobuntu <[email protected]>
Mingcong Bai <[email protected]>
Nikos Chantziaras <[email protected]>
Noah Brecht <[email protected]>
Ododo <[email protected]>
Olivier Humbert <[email protected]>
Paul Nasca <zynaddsubfx_AT_yahoo com>
Peter Nelson <[email protected]>
Ra <[email protected]>
Ron U <[email protected]>
Ryan Schmidt <[email protected]>
Shane Ambler <[email protected]>
Simon Jackson (Netbook) <[email protected]>
Expand All @@ -170,13 +182,15 @@ follower <[email protected]>
fundamental <[email protected]>
gandalf3 <[email protected]>
groboclown <[email protected]>
https://gitlab.com/users/CYBERDEViLNL <[email protected]>
irrenhaus3 <[email protected]>
jasp00 <[email protected]>
justnope <[email protected]>
kamnxt <[email protected]>
knittl <[email protected]>
lmmsservice <[email protected]>
m-xbutterfly <[email protected]>
noahb01 <noahb2713@gmail.com>
necrashter <iiilker99@gmail.com>
projectpitchin <[email protected]>
rgwan <[email protected]>
xhe <[email protected]>
Expand Down
4 changes: 2 additions & 2 deletions src/core/Track.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -774,12 +774,12 @@ void TrackContentObjectView::mousePressEvent( QMouseEvent * me )
m_action = ResizeLeft;
setCursor( Qt::SizeHorCursor );
}
else if( me->x() < width() - RESIZE_GRIP_WIDTH )
else if( m_tco->getAutoResize() || me->x() < width() - RESIZE_GRIP_WIDTH )
{
m_action = Move;
setCursor( Qt::SizeAllCursor );
}
else if( !m_tco->getAutoResize() )
else
{
m_action = Resize;
setCursor( Qt::SizeHorCursor );
Expand Down
23 changes: 11 additions & 12 deletions src/core/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -129,9 +129,10 @@ inline void loadTranslation( const QString & tname,
QTranslator * t = new QTranslator( QCoreApplication::instance() );
QString name = tname + ".qm";

t->load( name, dir );

QCoreApplication::instance()->installTranslator( t );
if (t->load(name, dir))
{
QCoreApplication::instance()->installTranslator(t);
}
}


Expand Down Expand Up @@ -723,18 +724,16 @@ int main( int argc, char * * argv )
pos = QLocale::system().name().left( 2 );
}

#ifdef LMMS_BUILD_WIN32
#undef QT_TRANSLATIONS_DIR
#define QT_TRANSLATIONS_DIR ConfigManager::inst()->localeDir()
#endif
// load actual translation for LMMS
loadTranslation( pos );

#ifdef QT_TRANSLATIONS_DIR
// load translation for Qt-widgets/-dialogs
loadTranslation( QString( "qt_" ) + pos,
QString( QT_TRANSLATIONS_DIR ) );
#ifdef QT_TRANSLATIONS_DIR
// load from the original path first
loadTranslation(QString("qt_") + pos, QT_TRANSLATIONS_DIR);
#endif
// load actual translation for LMMS
loadTranslation( pos );
// override it with bundled/custom one, if exists
loadTranslation(QString("qt_") + pos, ConfigManager::inst()->localeDir());


// try to set realtime priority
Expand Down

0 comments on commit c83c9bf

Please sign in to comment.