diff options
-rw-r--r-- | CMakeLists.txt | 118 | ||||
-rw-r--r-- | pvs2.config | 1 | ||||
-rw-r--r-- | pvs2.creator | 1 | ||||
-rw-r--r-- | pvs2.files | 93 | ||||
-rw-r--r-- | pvs2.includes | 18 | ||||
-rw-r--r-- | res/icons/altexit.svg (renamed from icons/altexit.svg) | 0 | ||||
-rw-r--r-- | res/icons/altterm.svg (renamed from icons/altterm.svg) | 0 | ||||
-rw-r--r-- | res/icons/broadcast.svg (renamed from icons/broadcast.svg) | 0 | ||||
-rw-r--r-- | res/icons/cam32.svg (renamed from icons/cam32.svg) | 0 | ||||
-rw-r--r-- | res/icons/cf_icon_cam.svg (renamed from icons/cf_icon_cam.svg) | 0 | ||||
-rw-r--r-- | res/icons/cf_icon_eye.svg (renamed from icons/cf_icon_eye.svg) | 0 | ||||
-rw-r--r-- | res/icons/cf_icon_lock.svg (renamed from icons/cf_icon_lock.svg) | 0 | ||||
-rw-r--r-- | res/icons/chat_msg16.svg (renamed from icons/chat_msg16.svg) | 0 | ||||
-rw-r--r-- | res/icons/dark-green-check-mark.svg (renamed from icons/dark-green-check-mark.svg) | 0 | ||||
-rw-r--r-- | res/icons/darrow16.svg (renamed from icons/darrow16.svg) | 0 | ||||
-rw-r--r-- | res/icons/dozent.svg (renamed from icons/dozent.svg) | 0 | ||||
-rw-r--r-- | res/icons/exit.svg (renamed from icons/exit.svg) | 0 | ||||
-rw-r--r-- | res/icons/eye.svg (renamed from icons/eye.svg) | 0 | ||||
-rw-r--r-- | res/icons/graduate.svg (renamed from icons/graduate.svg) | 0 | ||||
-rw-r--r-- | res/icons/hand-raise-red.svg (renamed from icons/hand-raise-red.svg) | 0 | ||||
-rw-r--r-- | res/icons/hand-raise.svg (renamed from icons/hand-raise.svg) | 0 | ||||
-rw-r--r-- | res/icons/help.svg (renamed from icons/help.svg) | 0 | ||||
-rw-r--r-- | res/icons/keyboard_key.svg (renamed from icons/keyboard_key.svg) | 0 | ||||
-rw-r--r-- | res/icons/lock-single.svg (renamed from icons/lock-single.svg) | 0 | ||||
-rw-r--r-- | res/icons/lock.svg (renamed from icons/lock.svg) | 0 | ||||
-rw-r--r-- | res/icons/log-out.svg (renamed from icons/log-out.svg) | 0 | ||||
-rw-r--r-- | res/icons/ok16.svg (renamed from icons/ok16.svg) | 0 | ||||
-rw-r--r-- | res/icons/photo.svg (renamed from icons/photo.svg) | 0 | ||||
-rw-r--r-- | res/icons/refresh.svg (renamed from icons/refresh.svg) | bin | 8103 -> 8103 bytes | |||
-rw-r--r-- | res/icons/reloadClassroom.svg (renamed from icons/reloadClassroom.svg) | 0 | ||||
-rw-r--r-- | res/icons/screen.svg (renamed from icons/screen.svg) | 0 | ||||
-rw-r--r-- | res/icons/space.svg (renamed from icons/space.svg) | 0 | ||||
-rw-r--r-- | res/icons/stopprojection.svg (renamed from icons/stopprojection.svg) | 0 | ||||
-rw-r--r-- | res/icons/student2all.svg (renamed from icons/student2all.svg) | 0 | ||||
-rw-r--r-- | res/icons/student2tutor.svg (renamed from icons/student2tutor.svg) | 0 | ||||
-rw-r--r-- | res/icons/student2tutor_extension.svg (renamed from icons/student2tutor_extension.svg) | 0 | ||||
-rw-r--r-- | res/icons/terminal.svg (renamed from icons/terminal.svg) | 0 | ||||
-rw-r--r-- | res/icons/trash.svg (renamed from icons/trash.svg) | 0 | ||||
-rw-r--r-- | res/icons/tutor2all.svg (renamed from icons/tutor2all.svg) | 0 | ||||
-rw-r--r-- | res/icons/tutor2student.svg (renamed from icons/tutor2student.svg) | 0 | ||||
-rw-r--r-- | res/icons/view-restore.svg (renamed from icons/view-restore.svg) | 0 | ||||
-rw-r--r-- | res/pvsclient.qrc (renamed from pvsclient.qrc) | 6 | ||||
-rw-r--r-- | res/pvsclient_ts.qrc | 9 | ||||
-rw-r--r-- | res/pvsmgr.qrc (renamed from pvsmgr.qrc) | 6 | ||||
-rw-r--r-- | res/pvsmgr_ts.qrc | 9 | ||||
-rw-r--r-- | src/client/clientapp/clientapp.cpp | 6 | ||||
-rw-r--r-- | src/client/connectwindow/connectwindow.cpp | 6 | ||||
-rw-r--r-- | src/client/connectwindow/connectwindow.h | 1 | ||||
-rw-r--r-- | src/client/connectwindow/connectwindow.ui (renamed from gui/client/connect.ui) | 0 | ||||
-rw-r--r-- | src/client/toolbar/toolbar.ui (renamed from gui/client/toolbar.ui) | 0 | ||||
-rw-r--r-- | src/server/mainwindow/mainwindow.cpp | 23 | ||||
-rw-r--r-- | src/server/mainwindow/mainwindow.ui (renamed from gui/server_normal/mainwindow.ui) | 0 | ||||
-rw-r--r-- | src/server/numerickeyboard/numerickeyboard.ui (renamed from gui/server_normal/numerickeyboard.ui) | 0 | ||||
-rw-r--r-- | src/server/reloadroomwindow/reloadroomwindow.cpp | 25 | ||||
-rw-r--r-- | src/server/reloadroomwindow/reloadroomwindow.h | 15 | ||||
-rw-r--r-- | src/server/reloadroomwindow/reloadroomwindow.ui (renamed from gui/server_normal/reloadroom.ui) | 0 | ||||
-rw-r--r-- | src/server/sessionnamewindow/sessionnamewindow.cpp | 2 | ||||
-rw-r--r-- | src/server/sessionnamewindow/sessionnamewindow.ui (renamed from gui/server_normal/sessionname.ui) | 0 |
58 files changed, 99 insertions, 240 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index 5e1b550..69efa33 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -17,6 +17,10 @@ SET(CMAKE_CXX_STANDARD 11) SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -std=c11 ${EXTRA_C_FLAGS}") SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11 ${EXTRA_CXX_FLAGS}") +set(CMAKE_AUTOMOC ON) +set(CMAKE_AUTORCC ON) +set(CMAKE_AUTOUIC ON) + # local cmake modules SET(CMAKE_MODULE_PATH ${CMAKE_SOURCE_DIR}/cmake) @@ -26,14 +30,13 @@ FIND_PACKAGE(X11 REQUIRED) FIND_PACKAGE(VNC REQUIRED) SET(CMAKE_INCLUDE_CURRENT_DIR ON) -SET(CMAKE_AUTOMOC ON) # some includes -INCLUDE_DIRECTORIES( - ${CMAKE_CURRENT_SOURCE_DIR} - ${CMAKE_CURRENT_BINARY_DIR} - ${X11_INCLUDE_DIR} -) +#INCLUDE_DIRECTORIES( +# ${CMAKE_CURRENT_SOURCE_DIR} +# ${CMAKE_CURRENT_BINARY_DIR} +# ${X11_INCLUDE_DIR} +#) IF(X11_Xscreensaver_FOUND) ADD_DEFINITIONS(-DX11_Xscreensaver_FOUND) @@ -78,20 +81,27 @@ FILE(GLOB PVSCLIENT_SRCS ################################################################################ # .ui files -FILE(GLOB PVSMGR_UIS - gui/server_normal/*.ui +FILE(GLOB_RECURSE PVSMGR_UIS + src/server/*.ui ) -FILE(GLOB PVSCLIENT_UIS - gui/client/*.ui +FILE(GLOB_RECURSE PVSCLIENT_UIS + src/client/*.ui ) # .qrc files +# Copy these to build dir since the paths inside are relative, and this is where the translations end up +configure_file(res/pvsmgr_ts.qrc ${CMAKE_CURRENT_BINARY_DIR} COPYONLY) +configure_file(res/pvsclient_ts.qrc ${CMAKE_CURRENT_BINARY_DIR} COPYONLY) + FILE(GLOB PVSMGR_RC_SRCS - pvsmgr.qrc + res/pvsmgr.qrc + ${CMAKE_CURRENT_BINARY_DIR}/pvsmgr_ts.qrc + ) FILE(GLOB PVSCLIENT_RC_SRCS - pvsclient.qrc + res/pvsclient.qrc + ${CMAKE_CURRENT_BINARY_DIR}/pvsclient_ts.qrc ) # i18n @@ -103,57 +113,12 @@ FILE(GLOB PVSCLIENT_TSS i18n/client/*.ts ) - -# this will run uic on .ui files -QT5_WRAP_UI(PVSMGR_UI_HDRS ${PVSMGR_UIS}) -QT5_WRAP_UI(PVSCLIENT_UI_HDRS ${PVSCLIENT_UIS}) - -# this will run moc -#QT4_WRAP_CPP(PVSMGR_MOC_SRCS ${PVSMGR_MOC_HDRS}) -#QT4_WRAP_CPP(PVSCLIENT_MOC_SRCS ${PVSCLIENT_MOC_HDRS}) - -option(UPDATE_TRANSLATIONS "Update .ts files (WARNING: make clean will delete the .ts files!)" OFF) - if(PVSMGR_TSS) - - if (UPDATE_TRANSLATIONS) - set(FILES_TO_TRANSLATE ${PVSMGR_SRCS} ${PVSMGR_UIS}) - QT5_CREATE_TRANSLATION(PVSMGR_QMS ${FILES_TO_TRANSLATE} ${PVSMGR_TSS} OPTIONS -noobsolete) - message(STATUS ".tr files have been updated") - else (UPDATE_TRANSLATIONS) - QT5_ADD_TRANSLATION(PVSMGR_QMS ${PVSMGR_TSS}) - endif (UPDATE_TRANSLATIONS) - # # write a resource file for qm files - # set(resource_file_content "<RCC>\n <qresource prefix=\"/\">\n") - # foreach(file ${PVSMGR_QMS}) - # get_filename_component(filename ${file} NAME) - # set(resource_file_content "${resource_file_content} <file>${filename}</file>\n") - # endforeach(file) - # set(resource_file_content "${resource_file_content} </qresource>\n</RCC>\n") - # file(WRITE "${CMAKE_BINARY_DIR}/ts_pvsmgr.qrc" "${resource_file_content}") - # set(PVSMGR_RESOURCES ${PVSMGR_RESOURCES} "${CMAKE_BINARY_DIR}/ts_pvsmgr.qrc") - + QT5_CREATE_TRANSLATION(PVSMGR_QMS ${PVSMGR_UIS} ${PVSMGR_SRCS} ${PVSMGR_TSS} OPTIONS -noobsolete) endif(PVSMGR_TSS) if(PVSCLIENT_TSS) - - if (UPDATE_TRANSLATIONS) - set(FILES_TO_TRANSLATE ${PVSCLIENT_SRCS} ${PVSCLIENT_UIS}) - QT5_CREATE_TRANSLATION(PVSCLIENT_QMS ${FILES_TO_TRANSLATE} ${PVSCLIENT_TSS} OPTIONS -noobsolete) - message(STATUS ".tr files have been updated") - else (UPDATE_TRANSLATIONS) - QT5_ADD_TRANSLATION(PVSCLIENT_QMS ${PVSCLIENT_TSS}) - endif (UPDATE_TRANSLATIONS) - # # write a resource file for qm files - # set(resource_file_content "<RCC>\n <qresource prefix=\"/\">\n") - # foreach(file ${PVSCLIENT_QMS}) - # get_filename_component(filename ${file} NAME) - # set(resource_file_content "${resource_file_content} <file>${filename}</file>\n") - # endforeach(file) - # set(resource_file_content "${resource_file_content} </qresource>\n</RCC>\n") - # file(WRITE "${CMAKE_BINARY_DIR}/ts_pvsclient.qrc" "${resource_file_content}") - # set(PVSCLIENT_RESOURCES ${PVSCLIENT_RESOURCES} "${CMAKE_BINARY_DIR}/ts_pvsclient.qrc") - + QT5_CREATE_TRANSLATION(PVSCLIENT_QMS ${PVSCLIENT_UIS} ${PVSCLIENT_SRCS} ${PVSCLIENT_TSS} OPTIONS -noobsolete) endif(PVSCLIENT_TSS) # this will run rcc on .qrc files @@ -167,8 +132,6 @@ QT5_ADD_RESOURCES(PVSCLIENT_RCS ${PVSCLIENT_RC_SRCS}) ADD_EXECUTABLE(pvsmgr ${PVSMGR_SRCS} ${PVSMGR_RCS} -# ${PVSMGR_MOC_SRCS} - ${PVSMGR_UI_HDRS} ${PVSMGR_RC_SRCS} ${PVSMGR_QMS} ) @@ -176,8 +139,6 @@ ADD_EXECUTABLE(pvsmgr ADD_EXECUTABLE(pvsclient ${PVSCLIENT_SRCS} ${PVSCLIENT_RCS} -# ${PVSCLIENT_MOC_SRCS} - ${PVSCLIENT_UI_HDRS} ${PVSCLIENT_RC_SRCS} ${PVSCLIENT_QMS} ) @@ -188,7 +149,6 @@ TARGET_LINK_LIBRARIES(pvsmgr Qt5::Widgets Qt5::Svg Qt5::X11Extras -# ${VNC_LIBRARIES} ${X11_LIBRARIES} ${X11_Xscreensaver_LIB} ) @@ -204,33 +164,3 @@ SET_PROPERTY(TARGET pvsmgr PROPERTY COMPILE_DEFINITIONS MAINWINDOW_USE_NORMALGUI # install INSTALL(TARGETS pvsmgr pvsclient RUNTIME DESTINATION bin) -#INSTALL(PROGRAMS misc/pvs-vncsrv DESTINATION bin) -#INSTALL(FILES misc/pvsclient.conf misc/pvsmgr.conf DESTINATION /etc/openslx) -#INSTALL(FILES misc/pvsclient.desktop DESTINATION /etc/xdg/autostart) - -# uninstall -CONFIGURE_FILE( - "${CMAKE_CURRENT_SOURCE_DIR}/cmake/Uninstall.cmake" - "${CMAKE_CURRENT_BINARY_DIR}/cmake/Uninstall.cmake" - IMMEDIATE @ONLY -) -ADD_CUSTOM_TARGET(uninstall - "${CMAKE_COMMAND}" -P "${CMAKE_CURRENT_BINARY_DIR}/cmake/Uninstall.cmake" -) - -# package -SET( CPACK_GENERATOR "DEB" ) -SET( CPACK_SET_DESTDIR "ON" ) -SET( CPACK_PACKAGE_NAME "pvs" ) -SET( CPACK_PACKAGE_VERSION_MAJOR "3" ) -SET( CPACK_PACKAGE_VERSION_MINOR "1" ) -SET( CPACK_PACKAGE_VERSION_PATCH "2" ) -SET( CPACK_PACKAGE_DESCRIPTION_SUMMARY "Pool Video Switch" ) -SET( CPACK_PACKAGE_DESCRIPTION "") -SET( CPACK_PACKAGE_CONTACT "Johann Latocha <johann@latocha.de>" ) -SET( CPACK_DEBIAN_PACKAGE_DEPENDS "libvncserver0 (>= 0.9.3.dfsg.1-2), libqtgui4 (>= 4:4.5.3-4), libqt4-dbus (>= 4:4.5.3-4), libqt4-network (>= 4:4.5.3-4)" ) -SET( CPACK_DEBIAN_PACKAGE_ARCHITECTURE "i386" ) -SET( CPACK_DEBIAN_PACKAGE_SECTION "Network" ) -SET( CPACK_DEBIAN_PACKAGE_PRIORITY "optional" ) -SET( CPACK_DEBIAN_PACKAGE_RECOMMENDS "x11vnc (>= 0.9.9-1)" ) -INCLUDE( CPack ) diff --git a/pvs2.config b/pvs2.config deleted file mode 100644 index 8cec188..0000000 --- a/pvs2.config +++ /dev/null @@ -1 +0,0 @@ -// ADD PREDEFINED MACROS HERE! diff --git a/pvs2.creator b/pvs2.creator deleted file mode 100644 index e94cbbd..0000000 --- a/pvs2.creator +++ /dev/null @@ -1 +0,0 @@ -[General] diff --git a/pvs2.files b/pvs2.files deleted file mode 100644 index 599b005..0000000 --- a/pvs2.files +++ /dev/null @@ -1,93 +0,0 @@ -build/CMakeFiles/2.8.12.2/CompilerIdC/CMakeCCompilerId.c -build/CMakeFiles/2.8.12.2/CompilerIdCXX/CMakeCXXCompilerId.cpp -build/src/client/connectwindow/moc_connectwindow.cxx -build/src/client/net/moc_serverconnection.cxx -build/src/client/net/moc_serverdiscovery.cxx -build/src/client/toolbar/moc_toolbar.cxx -build/src/client/util/platform/moc_blankscreen.cxx -build/src/client/util/moc_util.cxx -build/src/client/vnc/moc_vncserver.cxx -build/src/client/vnc/moc_vncthread.cxx -build/src/client/vnc/moc_vncwindow.cxx -build/src/server/clicklabel/moc_clicklabel.cxx -build/src/server/connectionframe/moc_connectionframe.cxx -build/src/server/helpwindow/moc_helpwindow.cxx -build/src/server/mainwindow/moc_mainwindow.cxx -build/src/server/net/moc_certmanager.cxx -build/src/server/net/moc_client.cxx -build/src/server/net/moc_discoverylistener.cxx -build/src/server/net/moc_filedownloader.cxx -build/src/server/net/moc_listenserver.cxx -build/src/server/net/moc_sslserver.cxx -build/src/server/reloadroomwindow/moc_reloadroomwindow.cxx -build/src/server/reloadwindow/moc_reloadwindow.cxx -build/src/server/sessionnamewindow/moc_sessionnamewindow.cxx -build/src/server/util/moc_global.cxx -build/src/server/util/moc_util.cxx -build/qrc_pvsclient.cxx -build/qrc_pvsmgr.cxx -build/ui_connect.h -build/ui_help.h -build/ui_mainwindow.h -build/ui_reloadroom.h -build/ui_sessionname.h -build/ui_toolbar.h -src/client/connectwindow/connectwindow.cpp -src/client/connectwindow/connectwindow.h -src/client/net/serverconnection.cpp -src/client/net/serverconnection.h -src/client/net/serverdiscovery.cpp -src/client/net/serverdiscovery.h -src/client/toolbar/toolbar.cpp -src/client/toolbar/toolbar.h -src/client/util/platform/blankscreen.h -src/client/util/platform/blankscreen_Win32.cpp -src/client/util/platform/blankscreen_X11.cpp -src/client/util/util.cpp -src/client/util/util.h -src/client/vnc/vncserver.cpp -src/client/vnc/vncserver.h -src/client/vnc/vncthread.cpp -src/client/vnc/vncthread.h -src/client/vnc/vncwindow.cpp -src/client/vnc/vncwindow.h -src/client/main.cpp -src/server/clicklabel/clicklabel.cpp -src/server/clicklabel/clicklabel.h -src/server/connectionframe/connectionframe.cpp -src/server/connectionframe/connectionframe.h -src/server/helpwindow/helpwindow.cpp -src/server/helpwindow/helpwindow.h -src/server/mainwindow/mainwindow.cpp -src/server/mainwindow/mainwindow.h -src/server/net/certmanager.cpp -src/server/net/certmanager.h -src/server/net/client.cpp -src/server/net/client.h -src/server/net/discoverylistener.cpp -src/server/net/discoverylistener.h -src/server/net/filedownloader.cpp -src/server/net/filedownloader.h -src/server/net/listenserver.cpp -src/server/net/listenserver.h -src/server/net/sslserver.cpp -src/server/net/sslserver.h -src/server/reloadroomwindow/reloadroomwindow.cpp -src/server/reloadroomwindow/reloadroomwindow.h -src/server/sessionnamewindow/sessionnamewindow.cpp -src/server/sessionnamewindow/sessionnamewindow.h -src/server/util/global.cpp -src/server/util/global.h -src/server/util/util.cpp -src/server/util/util.h -src/server/main.cpp -src/shared/network.cpp -src/shared/network.h -src/shared/networkmessage.cpp -src/shared/networkmessage.h -src/shared/settings.h -src/shared/util.cpp -src/shared/util.h -src/server/numerickeyboard/numerickeyboard.h -src/server/numerickeyboard/numerickeyboard.cpp -gui/numerickeyboard.ui diff --git a/pvs2.includes b/pvs2.includes deleted file mode 100644 index 0d3fb41..0000000 --- a/pvs2.includes +++ /dev/null @@ -1,18 +0,0 @@ -build -src/client/connectwindow -src/client/net -src/client/toolbar -src/client/util -src/client/util/platform -src/client/vnc -src/server/clicklabel -src/server/connectionframe -src/server/helpwindow -src/server/mainwindow -src/server/net -src/server/reloadroomwindow -src/server/sessionnamewindow -src/server/util -src/shared -gui -src/server/numerickeyboard diff --git a/icons/altexit.svg b/res/icons/altexit.svg index 5331ab6..5331ab6 100644 --- a/icons/altexit.svg +++ b/res/icons/altexit.svg diff --git a/icons/altterm.svg b/res/icons/altterm.svg index 2197700..2197700 100644 --- a/icons/altterm.svg +++ b/res/icons/altterm.svg diff --git a/icons/broadcast.svg b/res/icons/broadcast.svg index 9d8b2f5..9d8b2f5 100644 --- a/icons/broadcast.svg +++ b/res/icons/broadcast.svg diff --git a/icons/cam32.svg b/res/icons/cam32.svg index c3f085c..c3f085c 100644 --- a/icons/cam32.svg +++ b/res/icons/cam32.svg diff --git a/icons/cf_icon_cam.svg b/res/icons/cf_icon_cam.svg index c51ab6d..c51ab6d 100644 --- a/icons/cf_icon_cam.svg +++ b/res/icons/cf_icon_cam.svg diff --git a/icons/cf_icon_eye.svg b/res/icons/cf_icon_eye.svg index cfda228..cfda228 100644 --- a/icons/cf_icon_eye.svg +++ b/res/icons/cf_icon_eye.svg diff --git a/icons/cf_icon_lock.svg b/res/icons/cf_icon_lock.svg index 5700e7d..5700e7d 100644 --- a/icons/cf_icon_lock.svg +++ b/res/icons/cf_icon_lock.svg diff --git a/icons/chat_msg16.svg b/res/icons/chat_msg16.svg index 1e4be83..1e4be83 100644 --- a/icons/chat_msg16.svg +++ b/res/icons/chat_msg16.svg diff --git a/icons/dark-green-check-mark.svg b/res/icons/dark-green-check-mark.svg index ac4238d..ac4238d 100644 --- a/icons/dark-green-check-mark.svg +++ b/res/icons/dark-green-check-mark.svg diff --git a/icons/darrow16.svg b/res/icons/darrow16.svg index 4b1609a..4b1609a 100644 --- a/icons/darrow16.svg +++ b/res/icons/darrow16.svg diff --git a/icons/dozent.svg b/res/icons/dozent.svg index 056a339..056a339 100644 --- a/icons/dozent.svg +++ b/res/icons/dozent.svg diff --git a/icons/exit.svg b/res/icons/exit.svg index d8766c9..d8766c9 100644 --- a/icons/exit.svg +++ b/res/icons/exit.svg diff --git a/icons/eye.svg b/res/icons/eye.svg index 86518ca..86518ca 100644 --- a/icons/eye.svg +++ b/res/icons/eye.svg diff --git a/icons/graduate.svg b/res/icons/graduate.svg index 63f9f88..63f9f88 100644 --- a/icons/graduate.svg +++ b/res/icons/graduate.svg diff --git a/icons/hand-raise-red.svg b/res/icons/hand-raise-red.svg index 1391d3e..1391d3e 100644 --- a/icons/hand-raise-red.svg +++ b/res/icons/hand-raise-red.svg diff --git a/icons/hand-raise.svg b/res/icons/hand-raise.svg index 8dcbab1..8dcbab1 100644 --- a/icons/hand-raise.svg +++ b/res/icons/hand-raise.svg diff --git a/icons/help.svg b/res/icons/help.svg index 2e97f37..2e97f37 100644 --- a/icons/help.svg +++ b/res/icons/help.svg diff --git a/icons/keyboard_key.svg b/res/icons/keyboard_key.svg index c6cc88e..c6cc88e 100644 --- a/icons/keyboard_key.svg +++ b/res/icons/keyboard_key.svg diff --git a/icons/lock-single.svg b/res/icons/lock-single.svg index 5e0cd95..5e0cd95 100644 --- a/icons/lock-single.svg +++ b/res/icons/lock-single.svg diff --git a/icons/lock.svg b/res/icons/lock.svg index 6359f2c..6359f2c 100644 --- a/icons/lock.svg +++ b/res/icons/lock.svg diff --git a/icons/log-out.svg b/res/icons/log-out.svg index e94c873..e94c873 100644 --- a/icons/log-out.svg +++ b/res/icons/log-out.svg diff --git a/icons/ok16.svg b/res/icons/ok16.svg index 3d60d49..3d60d49 100644 --- a/icons/ok16.svg +++ b/res/icons/ok16.svg diff --git a/icons/photo.svg b/res/icons/photo.svg index 6552735..6552735 100644 --- a/icons/photo.svg +++ b/res/icons/photo.svg diff --git a/icons/refresh.svg b/res/icons/refresh.svg Binary files differindex e499882..e499882 100644 --- a/icons/refresh.svg +++ b/res/icons/refresh.svg diff --git a/icons/reloadClassroom.svg b/res/icons/reloadClassroom.svg index e3dfe62..e3dfe62 100644 --- a/icons/reloadClassroom.svg +++ b/res/icons/reloadClassroom.svg diff --git a/icons/screen.svg b/res/icons/screen.svg index 17abe8b..17abe8b 100644 --- a/icons/screen.svg +++ b/res/icons/screen.svg diff --git a/icons/space.svg b/res/icons/space.svg index 797cbc8..797cbc8 100644 --- a/icons/space.svg +++ b/res/icons/space.svg diff --git a/icons/stopprojection.svg b/res/icons/stopprojection.svg index 90e6425..90e6425 100644 --- a/icons/stopprojection.svg +++ b/res/icons/stopprojection.svg diff --git a/icons/student2all.svg b/res/icons/student2all.svg index 5971d45..5971d45 100644 --- a/icons/student2all.svg +++ b/res/icons/student2all.svg diff --git a/icons/student2tutor.svg b/res/icons/student2tutor.svg index c40c478..c40c478 100644 --- a/icons/student2tutor.svg +++ b/res/icons/student2tutor.svg diff --git a/icons/student2tutor_extension.svg b/res/icons/student2tutor_extension.svg index 5a8cf5e..5a8cf5e 100644 --- a/icons/student2tutor_extension.svg +++ b/res/icons/student2tutor_extension.svg diff --git a/icons/terminal.svg b/res/icons/terminal.svg index d9b5a2d..d9b5a2d 100644 --- a/icons/terminal.svg +++ b/res/icons/terminal.svg diff --git a/icons/trash.svg b/res/icons/trash.svg index e217a09..e217a09 100644 --- a/icons/trash.svg +++ b/res/icons/trash.svg diff --git a/icons/tutor2all.svg b/res/icons/tutor2all.svg index cf46921..cf46921 100644 --- a/icons/tutor2all.svg +++ b/res/icons/tutor2all.svg diff --git a/icons/tutor2student.svg b/res/icons/tutor2student.svg index 2f88720..2f88720 100644 --- a/icons/tutor2student.svg +++ b/res/icons/tutor2student.svg diff --git a/icons/view-restore.svg b/res/icons/view-restore.svg index 000c826..000c826 100644 --- a/icons/view-restore.svg +++ b/res/icons/view-restore.svg diff --git a/pvsclient.qrc b/res/pvsclient.qrc index b5fcd79..3e04631 100644 --- a/pvsclient.qrc +++ b/res/pvsclient.qrc @@ -11,11 +11,5 @@ <file alias="help">icons/help.svg</file> <file alias="hand-raise">icons/hand-raise.svg</file> <file alias="hand-raise-red">icons/hand-raise-red.svg</file> - <file alias="AUTHORS">AUTHORS</file> - <file alias="l_de">build/pvsclient_de_DE.qm</file> - <file alias="l_fr">build/pvsclient_fr_FR.qm</file> - <file alias="l_es_MX">build/pvsclient_es_MX.qm</file> - <file alias="l_ar_JO">build/pvsclient_ar_JO.qm</file> - <file alias="l_pl">build/pvsclient_pl_PL.qm</file> </qresource> </RCC> diff --git a/res/pvsclient_ts.qrc b/res/pvsclient_ts.qrc new file mode 100644 index 0000000..1640f3f --- /dev/null +++ b/res/pvsclient_ts.qrc @@ -0,0 +1,9 @@ +<RCC> + <qresource prefix="/"> + <file alias="l_de">pvsclient_de_DE.qm</file> + <file alias="l_fr">pvsclient_fr_FR.qm</file> + <file alias="l_es_MX">pvsclient_es_MX.qm</file> + <file alias="l_ar_JO">pvsclient_ar_JO.qm</file> + <file alias="l_pl">pvsclient_pl_PL.qm</file> + </qresource> +</RCC> diff --git a/pvsmgr.qrc b/res/pvsmgr.qrc index b6bd891..1070fe7 100644 --- a/pvsmgr.qrc +++ b/res/pvsmgr.qrc @@ -18,14 +18,8 @@ <file alias="helpme">icons/help.svg</file> <file alias="trash">icons/trash.svg</file> <file alias="reloadClassroom">icons/reloadClassroom.svg</file> - <file alias="AUTHORS">AUTHORS</file> <file alias="cf_cam">icons/cf_icon_cam.svg</file> <file alias="cf_eye">icons/cf_icon_eye.svg</file> <file alias="cf_lock">icons/cf_icon_lock.svg</file> - <file alias="l_de">build/pvsmgr_de_DE.qm</file> - <file alias="l_fr">build/pvsmgr_fr_FR.qm</file> - <file alias="l_es_MX">build/pvsmgr_es_MX.qm</file> - <file alias="l_ar_JO">build/pvsmgr_ar_JO.qm</file> - <file alias="l_pl">build/pvsmgr_pl_PL.qm</file> </qresource> </RCC> diff --git a/res/pvsmgr_ts.qrc b/res/pvsmgr_ts.qrc new file mode 100644 index 0000000..8ba5846 --- /dev/null +++ b/res/pvsmgr_ts.qrc @@ -0,0 +1,9 @@ +<RCC> + <qresource> + <file alias="l_de">pvsmgr_de_DE.qm</file> + <file alias="l_fr">pvsmgr_fr_FR.qm</file> + <file alias="l_es_MX">pvsmgr_es_MX.qm</file> + <file alias="l_ar_JO">pvsmgr_ar_JO.qm</file> + <file alias="l_pl">pvsmgr_pl_PL.qm</file> + </qresource> +</RCC> diff --git a/src/client/clientapp/clientapp.cpp b/src/client/clientapp/clientapp.cpp index 2447526..8131e6f 100644 --- a/src/client/clientapp/clientapp.cpp +++ b/src/client/clientapp/clientapp.cpp @@ -23,14 +23,14 @@ ClientApp::ClientApp(int& argc, char** argv) // System strings QTranslator *qtTranslator = new QTranslator(this); if (!qtTranslator->load(QLocale::system(), "qt", "_", QLibraryInfo::location(QLibraryInfo::TranslationsPath))) { - qDebug() << "Could not load system string translations"; + qDebug() << "Could not load system string translations" << QLocale::system() << QLibraryInfo::location(QLibraryInfo::TranslationsPath); } else { installTranslator(qtTranslator); } // App specific QTranslator *translator = new QTranslator(this); - if (!translator->load(QLocale::system(), ":", "l_")) { - qDebug() << "Could not load app translations"; + if (!translator->load(QLocale::system(), ":/", "l_")) { + qDebug() << "Could not load app translations" << QLocale::system(); } else { installTranslator(translator); } diff --git a/src/client/connectwindow/connectwindow.cpp b/src/client/connectwindow/connectwindow.cpp index 7674cc2..8c47eea 100644 --- a/src/client/connectwindow/connectwindow.cpp +++ b/src/client/connectwindow/connectwindow.cpp @@ -12,11 +12,15 @@ #include "../net/serverconnection.h" #include "../clientapp/clientapp.h" #include "connectwindow.h" -#include "ui_connect.h" +#include "ui_connectwindow.h" #define UDPBUFSIZ 9000 #define SALT_LEN 18 +namespace Ui { + class ConnectWindow; +} + /** * Initialize Connection Window. * @param parent diff --git a/src/client/connectwindow/connectwindow.h b/src/client/connectwindow/connectwindow.h index 9fcaf4e..2df672d 100644 --- a/src/client/connectwindow/connectwindow.h +++ b/src/client/connectwindow/connectwindow.h @@ -28,6 +28,7 @@ namespace Ui { class ConnectWindow; } + class ServerConnection; /** diff --git a/gui/client/connect.ui b/src/client/connectwindow/connectwindow.ui index 0bfc654..0bfc654 100644 --- a/gui/client/connect.ui +++ b/src/client/connectwindow/connectwindow.ui diff --git a/gui/client/toolbar.ui b/src/client/toolbar/toolbar.ui index 9908dda..9908dda 100644 --- a/gui/client/toolbar.ui +++ b/src/client/toolbar/toolbar.ui diff --git a/src/server/mainwindow/mainwindow.cpp b/src/server/mainwindow/mainwindow.cpp index f6ff566..b63545f 100644 --- a/src/server/mainwindow/mainwindow.cpp +++ b/src/server/mainwindow/mainwindow.cpp @@ -38,7 +38,6 @@ #include "../util/platform/screensaver.h" // Auto-generated ui class #include "ui_mainwindow.h" -#include "ui_reloadroom.h" #include <iostream> #include <vector> @@ -711,20 +710,20 @@ void MainWindow::startVncServerIfNecessary(int from) void MainWindow::onButtonReloadRoomConfig() { - connect(_reloadWindow->ui->buttonBox, SIGNAL(accepted()), this, SLOT(onReloadRoomOk())); - connect(_reloadWindow->ui->buttonBox, SIGNAL(rejected()), this, SLOT(onReloadRoomCancel())); + connect(_reloadWindow->buttonBox(), SIGNAL(accepted()), this, SLOT(onReloadRoomOk())); + connect(_reloadWindow->buttonBox(), SIGNAL(rejected()), this, SLOT(onReloadRoomCancel())); QList<QString> keyList = serverApp->getRooms().keys(); for (QList<QString>::iterator it = keyList.begin(); it != keyList.end() ; it++) { - _reloadWindow->ui->roomList->addItem(*it); + _reloadWindow->addRoom(*it); } _reloadWindow->show(); } void MainWindow::onReloadRoomCancel() { - disconnect(_reloadWindow->ui->buttonBox, SIGNAL(accepted()), this, SLOT(onReloadRoomOk())); - disconnect(_reloadWindow->ui->buttonBox, SIGNAL(rejected()), this, SLOT(onReloadRoomCancel())); - _reloadWindow->ui->roomList->clear(); + disconnect(_reloadWindow->buttonBox(), SIGNAL(accepted()), this, SLOT(onReloadRoomOk())); + disconnect(_reloadWindow->buttonBox(), SIGNAL(rejected()), this, SLOT(onReloadRoomCancel())); + _reloadWindow->clearRoomList(); _reloadWindow->hide(); } @@ -785,7 +784,8 @@ void MainWindow::reloadCurrentRoom() void MainWindow::onReloadRoomOk() { - if (_reloadWindow->ui->roomList->currentItem() == nullptr) { + QString roomToReload = _reloadWindow->currentRoom(); + if (roomToReload.isEmpty()) { QMessageBox::critical(this, "Warning", tr("No item selected, please select room!"), 0, 1); return; } @@ -794,8 +794,8 @@ void MainWindow::onReloadRoomOk() "Note that all clients will be deleted."), QMessageBox::Yes | QMessageBox::No, QMessageBox::Yes); if (ret == QMessageBox::Yes) { - disconnect(_reloadWindow->ui->buttonBox, SIGNAL(accepted()), this, SLOT(onReloadRoomOk())); - disconnect(_reloadWindow->ui->buttonBox, SIGNAL(rejected()), this, SLOT(onReloadRoomCancel())); + disconnect(_reloadWindow->buttonBox(), SIGNAL(accepted()), this, SLOT(onReloadRoomOk())); + disconnect(_reloadWindow->buttonBox(), SIGNAL(rejected()), this, SLOT(onReloadRoomCancel())); // Delete all clients. for (QList<ConnectionFrame*>::iterator it = _clientFrames.begin(); it != _clientFrames.end(); it++) { (*it)->hide(); @@ -804,11 +804,10 @@ void MainWindow::onReloadRoomOk() _clientFrames.clear(); // Load new room configuration. - QString roomToReload = _reloadWindow->ui->roomList->currentItem()->data(0).toString(); serverApp->setCurrentRoom(roomToReload); reloadCurrentRoom(); - _reloadWindow->ui->roomList->clear(); + _reloadWindow->clearRoomList(); _reloadWindow->hide(); } diff --git a/gui/server_normal/mainwindow.ui b/src/server/mainwindow/mainwindow.ui index 62b92f7..62b92f7 100644 --- a/gui/server_normal/mainwindow.ui +++ b/src/server/mainwindow/mainwindow.ui diff --git a/gui/server_normal/numerickeyboard.ui b/src/server/numerickeyboard/numerickeyboard.ui index 2f83a2b..2f83a2b 100644 --- a/gui/server_normal/numerickeyboard.ui +++ b/src/server/numerickeyboard/numerickeyboard.ui diff --git a/src/server/reloadroomwindow/reloadroomwindow.cpp b/src/server/reloadroomwindow/reloadroomwindow.cpp index 3070148..aea6a96 100644 --- a/src/server/reloadroomwindow/reloadroomwindow.cpp +++ b/src/server/reloadroomwindow/reloadroomwindow.cpp @@ -1,5 +1,5 @@ #include "reloadroomwindow.h" -#include "ui_reloadroom.h" +#include "ui_reloadroomwindow.h" ReloadRoomWindow::ReloadRoomWindow(QWidget *parent) : QDialog(parent), ui(new Ui::ReloadRoom) @@ -11,3 +11,26 @@ ReloadRoomWindow::~ReloadRoomWindow() { delete ui; } + +QDialogButtonBox *ReloadRoomWindow::buttonBox() const +{ + return ui->buttonBox; +} + +void ReloadRoomWindow::addRoom(const QString &roomName) +{ + ui->roomList->addItem(roomName); +} + +void ReloadRoomWindow::clearRoomList() +{ + ui->roomList->clear(); +} + +QString ReloadRoomWindow::currentRoom() const +{ + auto *cur = ui->roomList->currentItem(); + if (cur == nullptr) + return QLatin1String(); + return cur->data(0).toString(); +} diff --git a/src/server/reloadroomwindow/reloadroomwindow.h b/src/server/reloadroomwindow/reloadroomwindow.h index 2d2ae85..2baf53f 100644 --- a/src/server/reloadroomwindow/reloadroomwindow.h +++ b/src/server/reloadroomwindow/reloadroomwindow.h @@ -8,19 +8,28 @@ namespace Ui class ReloadRoom; } +class QDialogButtonBox; + class ReloadRoomWindow : public QDialog { Q_OBJECT public: - explicit ReloadRoomWindow(QWidget *parent = 0); + explicit ReloadRoomWindow(QWidget *parent = nullptr); ~ReloadRoomWindow(); - Ui::ReloadRoom *ui; - // void show(); + QDialogButtonBox* buttonBox() const; + + void addRoom(const QString &roomName); + + void clearRoomList(); + + QString currentRoom() const; private: + Ui::ReloadRoom *ui; + }; #endif diff --git a/gui/server_normal/reloadroom.ui b/src/server/reloadroomwindow/reloadroomwindow.ui index 2fb723e..2fb723e 100644 --- a/gui/server_normal/reloadroom.ui +++ b/src/server/reloadroomwindow/reloadroomwindow.ui diff --git a/src/server/sessionnamewindow/sessionnamewindow.cpp b/src/server/sessionnamewindow/sessionnamewindow.cpp index 5671c39..f79efbf 100644 --- a/src/server/sessionnamewindow/sessionnamewindow.cpp +++ b/src/server/sessionnamewindow/sessionnamewindow.cpp @@ -18,7 +18,7 @@ #include "sessionnamewindow.h" #include "../serverapp/serverapp.h" #include "../numerickeyboard/numerickeyboard.h" -#include "ui_sessionname.h" +#include "ui_sessionnamewindow.h" SessionNameWindow::SessionNameWindow(QWidget *parent) : diff --git a/gui/server_normal/sessionname.ui b/src/server/sessionnamewindow/sessionnamewindow.ui index 299df3d..299df3d 100644 --- a/gui/server_normal/sessionname.ui +++ b/src/server/sessionnamewindow/sessionnamewindow.ui |