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
1 change: 0 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -188,7 +188,6 @@ CPackSourceConfig.cmake
compile_commands.json
convert.exe
.dir-locals.el
*-icon.png
*-icon-win-folder.png
*-sidebar.png
*-w10startmenu.png
Expand Down
4 changes: 4 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,9 @@ endif()

set(BIN_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/bin")

set(NMC_RCC_FILE "nmctheme_v1.rcc")
configure_file(${CMAKE_SOURCE_DIR}/${NMC_RCC_FILE} "${BIN_OUTPUT_DIRECTORY}/${NMC_RCC_FILE}" COPYONLY)

include(${CMAKE_SOURCE_DIR}/NEXTCLOUD.cmake)

set(QT_VERSION_MAJOR "6")
Expand Down Expand Up @@ -368,6 +371,7 @@ configure_file(version.h.in ${CMAKE_CURRENT_BINARY_DIR}/version.h)
if(BUILD_OWNCLOUD_OSX_BUNDLE)
install(FILES sync-exclude.lst DESTINATION ${OWNCLOUD_OSX_BUNDLE}/Contents/Resources/)
configure_file(sync-exclude.lst bin/${OWNCLOUD_OSX_BUNDLE}/Contents/Resources/sync-exclude.lst COPYONLY)
install(FILES nmctheme_v1.rcc DESTINATION ${OWNCLOUD_OSX_BUNDLE}/Contents/Resources/)
elseif(BUILD_CLIENT)
install( FILES sync-exclude.lst DESTINATION ${SYSCONFDIR}/${APPLICATION_SHORTNAME} )
configure_file(sync-exclude.lst bin/sync-exclude.lst COPYONLY)
Expand Down
326 changes: 326 additions & 0 deletions magenta_theme.qrc.in

Large diffs are not rendered by default.

Binary file added nmctheme_v1.rcc
Binary file not shown.
8 changes: 8 additions & 0 deletions src/gui/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,9 @@ endif()
configure_file(${CMAKE_SOURCE_DIR}/theme.qrc.in ${CMAKE_SOURCE_DIR}/theme.qrc)
set(theme_dir ${CMAKE_SOURCE_DIR}/theme)

#NMC customization: needed to find the ui file in a different location than the header file
set(CMAKE_AUTOUIC_SEARCH_PATHS "${CMAKE_SOURCE_DIR}/src/gui")

set(client_UI_SRCS
accountsettings.ui
conflictdialog.ui
Expand Down Expand Up @@ -260,6 +263,10 @@ set(client_SRCS
wizard/wizardproxysettingsdialog.cpp
)

file(GLOB NMC_FILES "nmcgui/*")
set(NMC_SRCS ${NMC_FILES})
list(APPEND client_SRCS ${NMC_SRCS})

if (NOT DISABLE_ACCOUNT_MIGRATION)
list(APPEND client_SRCS
legacyaccountselectiondialog.h
Expand Down Expand Up @@ -610,6 +617,7 @@ if(NOT BUILD_OWNCLOUD_OSX_BUNDLE)
install(FILES ${VISUAL_ELEMENTS} DESTINATION bin/visualelements)
install(FILES "${theme_dir}/${APPLICATION_EXECUTABLE}.VisualElementsManifest.xml" DESTINATION bin)
install(FILES ${client_I18N} DESTINATION i18n)
install(FILES ${CMAKE_SOURCE_DIR}/nmctheme_v1.rcc DESTINATION bin)
endif()

# we may not add MACOSX_BUNDLE here, if not building one
Expand Down
11 changes: 11 additions & 0 deletions src/gui/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,17 @@ int main(int argc, char **argv)
qputenv("QML_IMPORT_PATH", (QDir::currentPath() + QStringLiteral("/qml")).toLatin1());
#endif

bool resourceLoaded = false;
const QString currentPath = QDir::currentPath();

if (Utility::isMac()) {
resourceLoaded = QResource::registerResource(QDir::toNativeSeparators("/Applications/MagentaCLOUD.app/Contents/Resources/nmctheme_v1.rcc"));
}

if (Utility::isWindows() || !resourceLoaded) {
resourceLoaded = QResource::registerResource(QDir::toNativeSeparators(currentPath + "/nmctheme_v1.rcc"));
}

Q_INIT_RESOURCE(resources);
Q_INIT_RESOURCE(theme);

Expand Down
31 changes: 31 additions & 0 deletions theme.qrc.in
Original file line number Diff line number Diff line change
Expand Up @@ -291,5 +291,36 @@
<file>theme/chevron-double-up.svg</file>
<file>theme/call-notification.wav</file>
<file>theme/info.svg</file>

<!-- NMC CC icons -->
<file>theme/NMCIcons/accountAvatarIcon.svg</file>
<file>theme/NMCIcons/action-add.svg</file>
<file>theme/NMCIcons/cloud-security.svg</file>
<file>theme/NMCIcons/collapse-down.svg</file>
<file>theme/NMCIcons/collapse-right.svg</file>
<file>theme/NMCIcons/configuration1.png</file>
<file>theme/NMCIcons/configuration2.png</file>
<file>theme/NMCIcons/configuration3.png</file>
<file>theme/NMCIcons/logout.svg</file>
<file>theme/NMCIcons/navigation-left.svg</file>
<file>theme/NMCIcons/navigation-right.svg</file>
<file>theme/NMCIcons/pause.svg</file>
<file>theme/NMCIcons/remove.svg</file>
<file>theme/NMCIcons/website.svg</file>

<!-- NMC CMW icons -->
<file>theme/NMCIcons/accountAvatarIcon-white.svg</file>
<file>theme/NMCIcons/logout-white.svg</file>
<file>theme/NMCIcons/pause-white.svg</file>
<file>theme/NMCIcons/remove-white.svg</file>
<file>theme/NMCIcons/website-white.svg</file>
<file>theme/close-white.svg</file>
<file>theme/more-white.svg</file>
<file>theme/settings-white.svg</file>

<!-- NMC RWI icons -->
<file>theme/NMCIcons/ApplicationLogo.svg</file>
<file>theme/NMCIcons/folderLogo.svg</file>
<file>theme/NMCIcons/tlogocarrier.svg</file>
</qresource>
</RCC>
16 changes: 16 additions & 0 deletions theme/NMCIcons/ApplicationLogo.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
7 changes: 7 additions & 0 deletions theme/NMCIcons/accountAvatarIcon-white.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
7 changes: 7 additions & 0 deletions theme/NMCIcons/accountAvatarIcon.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
12 changes: 12 additions & 0 deletions theme/NMCIcons/action-add.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
7 changes: 7 additions & 0 deletions theme/NMCIcons/cloud-security.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
7 changes: 7 additions & 0 deletions theme/NMCIcons/collapse-down.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
7 changes: 7 additions & 0 deletions theme/NMCIcons/collapse-right.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added theme/NMCIcons/configuration1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added theme/NMCIcons/configuration2.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added theme/NMCIcons/configuration3.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
83 changes: 83 additions & 0 deletions theme/NMCIcons/folderLogo.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
7 changes: 7 additions & 0 deletions theme/NMCIcons/logout-white.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
7 changes: 7 additions & 0 deletions theme/NMCIcons/logout.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
12 changes: 12 additions & 0 deletions theme/NMCIcons/navigation-left.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
12 changes: 12 additions & 0 deletions theme/NMCIcons/navigation-right.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
7 changes: 7 additions & 0 deletions theme/NMCIcons/pause-white.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading