Skip to content

Commit

Permalink
Merge branch 'app_icons' into dev
Browse files Browse the repository at this point in the history
  • Loading branch information
xmdnx committed Nov 20, 2023
2 parents 522319d + 407aac7 commit fcdda7e
Show file tree
Hide file tree
Showing 75 changed files with 432 additions and 81 deletions.
11 changes: 10 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ The source code is published under GPLv3 with OpenSSL exception, the license is

* Sticker size setting
* Userpic corner radius
* Auto-hide notifications
* Auto-hiding notifications
* Side menu editor
* Hide phone number in profile
* Show user ID in profile
Expand Down Expand Up @@ -55,6 +55,12 @@ You can build rabbitGram Desktop yourself using [build instructions][build_instr
* [macOS][macos]
* [GNU/Linux using Docker][linux]

## Special thanks to

* [AyuGram Desktop][ayugram]
* [Kotatogram][kotatogram]
* [64Gram][64gram]

[//]: # (LINKS)
[telegram]: https://telegram.org
[license]: LICENSE
Expand All @@ -64,3 +70,6 @@ You can build rabbitGram Desktop yourself using [build instructions][build_instr
[linux]: docs/building-linux.md
[macos]: docs/building-mac.md
[build_instructions]: https://github.com/rabbitGramDesktop/rabbitGramDesktop#build-instructions
[ayugram]: https://github.com/AyuGram/AyuGramDesktop
[kotatogram]: https://github.com/kotatogram/kotatogram-desktop
[64gram]: https://github.com/TDesktop-x64/tdesktop
19 changes: 13 additions & 6 deletions Telegram/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -1254,13 +1254,19 @@ PRIVATE
profile/profile_block_widget.h
profile/profile_cover_drop_area.cpp
profile/profile_cover_drop_area.h
rabbit/lang/rabbit_lang.cpp
rabbit/lang/rabbit_lang.h
rabbit/settings/rabbit_settings.cpp
rabbit/settings/rabbit_settings.h
rabbit/settings_menu/rabbit_settings_menu.cpp
rabbit/settings_menu/rabbit_settings_menu.h
rabbit/ui/settings/icon_picker.cpp
rabbit/ui/settings/icon_picker.h
rabbit/ui/rabbit_assets.cpp
rabbit/ui/rabbit_assets.h
rabbit/utils/windows_utils.cpp
rabbit/utils/windows_utils.h
rabbit/rabbit_version.h
rabbit/rabbit_lang.cpp
rabbit/rabbit_lang.h
rabbit/rabbit_settings.cpp
rabbit/rabbit_settings.h
rabbit/rabbit_settings_menu.cpp
rabbit/rabbit_settings_menu.h
settings/cloud_password/settings_cloud_password_common.cpp
settings/cloud_password/settings_cloud_password_common.h
settings/cloud_password/settings_cloud_password_email.cpp
Expand Down Expand Up @@ -1509,6 +1515,7 @@ endif()

nice_target_sources(Telegram ${res_loc}
PRIVATE
qrc/rabbit/rabbit.qrc
qrc/emoji_1.qrc
qrc/emoji_2.qrc
qrc/emoji_3.qrc
Expand Down
Binary file added Telegram/Resources/art/rabbit/angel/app.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 Telegram/Resources/art/rabbit/angel/app_icon.ico
Binary file not shown.
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 Telegram/Resources/art/rabbit/color/app.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 Telegram/Resources/art/rabbit/color/app_icon.ico
Binary file not shown.
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 Telegram/Resources/art/rabbit/default/app.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 not shown.
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 Telegram/Resources/art/rabbit/impostor/app.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 not shown.
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 Telegram/Resources/art/rabbit/matrix/app.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 Telegram/Resources/art/rabbit/matrix/app_icon.ico
Binary file not shown.
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 Telegram/Resources/art/rabbit/moon/app.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 Telegram/Resources/art/rabbit/moon/app_icon.ico
Binary file not shown.
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 Telegram/Resources/art/rabbit/old/app.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 Telegram/Resources/art/rabbit/old/app_icon.ico
Binary file not shown.
Binary file added Telegram/Resources/art/rabbit/old/app_preview.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
15 changes: 6 additions & 9 deletions Telegram/Resources/icons/tray_monochrome.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
25 changes: 25 additions & 0 deletions Telegram/Resources/qrc/rabbit/rabbit.qrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
<RCC>
<qresource prefix="/gui">
<file alias="art/rabbit/angel/app.png">../../art/rabbit/angel/app.png</file>
<file alias="art/rabbit/angel/app_preview.png">../../art/rabbit/angel/app_preview.png</file>
<file alias="art/rabbit/angel/app_icon.ico">../../art/rabbit/angel/app_icon.ico</file>
<file alias="art/rabbit/color/app.png">../../art/rabbit/color/app.png</file>
<file alias="art/rabbit/color/app_preview.png">../../art/rabbit/color/app_preview.png</file>
<file alias="art/rabbit/color/app_icon.ico">../../art/rabbit/color/app_icon.ico</file>
<file alias="art/rabbit/default/app.png">../../art/rabbit/default/app.png</file>
<file alias="art/rabbit/default/app_preview.png">../../art/rabbit/default/app_preview.png</file>
<file alias="art/rabbit/default/app_icon.ico">../../art/rabbit/default/app_icon.ico</file>
<file alias="art/rabbit/impostor/app.png">../../art/rabbit/impostor/app.png</file>
<file alias="art/rabbit/impostor/app_preview.png">../../art/rabbit/impostor/app_preview.png</file>
<file alias="art/rabbit/impostor/app_icon.ico">../../art/rabbit/impostor/app_icon.ico</file>
<file alias="art/rabbit/matrix/app.png">../../art/rabbit/matrix/app.png</file>
<file alias="art/rabbit/matrix/app_preview.png">../../art/rabbit/matrix/app_preview.png</file>
<file alias="art/rabbit/matrix/app_icon.ico">../../art/rabbit/matrix/app_icon.ico</file>
<file alias="art/rabbit/moon/app.png">../../art/rabbit/moon/app.png</file>
<file alias="art/rabbit/moon/app_preview.png">../../art/rabbit/moon/app_preview.png</file>
<file alias="art/rabbit/moon/app_icon.ico">../../art/rabbit/moon/app_icon.ico</file>
<file alias="art/rabbit/old/app.png">../../art/rabbit/old/app.png</file>
<file alias="art/rabbit/old/app_preview.png">../../art/rabbit/old/app_preview.png</file>
<file alias="art/rabbit/old/app_icon.ico">../../art/rabbit/old/app_icon.ico</file>
</qresource>
</RCC>
2 changes: 1 addition & 1 deletion Telegram/SourceFiles/boxes/about_box.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ For license and copyright information please follow this link:
https://github.com/rabbitgramdesktop/rabbitgramdesktop/blob/dev/LEGAL
*/
#include "boxes/about_box.h"
#include "rabbit/rabbit_lang.h"
#include "rabbit/lang/rabbit_lang.h"

#include "lang/lang_keys.h"
#include "mainwidget.h"
Expand Down
2 changes: 1 addition & 1 deletion Telegram/SourceFiles/boxes/download_path_box.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ For license and copyright information please follow this link:
https://github.com/rabbitgramdesktop/rabbitgramdesktop/blob/dev/LEGAL
*/
#include "boxes/download_path_box.h"
#include "rabbit/rabbit_lang.h"
#include "rabbit/lang/rabbit_lang.h"

#include "lang/lang_keys.h"
#include "core/file_utilities.h"
Expand Down
2 changes: 1 addition & 1 deletion Telegram/SourceFiles/boxes/peer_list_box.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ For license and copyright information please follow this link:
#include "data/data_session.h"
#include "data/data_changes.h"
#include "base/unixtime.h"
#include "rabbit/rabbit_settings.h"
#include "rabbit/settings/rabbit_settings.h"
#include "styles/style_layers.h"
#include "styles/style_boxes.h"
#include "styles/style_dialogs.h"
Expand Down
2 changes: 1 addition & 1 deletion Telegram/SourceFiles/calls/calls_userpic.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ For license and copyright information please follow this link:
#include "ui/empty_userpic.h"
#include "ui/painter.h"
#include "apiwrap.h" // requestFullPeer.
#include "rabbit/rabbit_settings.h"
#include "rabbit/settings/rabbit_settings.h"
#include "styles/style_calls.h"

namespace Calls {
Expand Down
2 changes: 1 addition & 1 deletion Telegram/SourceFiles/chat_helpers/field_autocomplete.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ For license and copyright information please follow this link:
https://github.com/rabbitgramdesktop/rabbitgramdesktop/blob/dev/LEGAL
*/
#include "chat_helpers/field_autocomplete.h"
#include "rabbit/rabbit_settings.h"
#include "rabbit/settings/rabbit_settings.h"

#include "data/data_document.h"
#include "data/data_document_media.h"
Expand Down
2 changes: 1 addition & 1 deletion Telegram/SourceFiles/core/application.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ For license and copyright information please follow this link:
https://github.com/rabbitgramdesktop/rabbitgramdesktop/blob/dev/LEGAL
*/
#include "core/application.h"
#include "rabbit/rabbit_lang.h"
#include "rabbit/lang/rabbit_lang.h"

#include "data/data_abstract_structure.h"
#include "data/data_photo.h"
Expand Down
2 changes: 1 addition & 1 deletion Telegram/SourceFiles/core/launcher.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ For license and copyright information please follow this link:
https://github.com/rabbitgramdesktop/rabbitgramdesktop/blob/dev/LEGAL
*/
#include "core/launcher.h"
#include "rabbit/rabbit_settings.h"
#include "rabbit/settings/rabbit_settings.h"

#include "platform/platform_launcher.h"
#include "platform/platform_specific.h"
Expand Down
2 changes: 1 addition & 1 deletion Telegram/SourceFiles/data/data_folder.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ For license and copyright information please follow this link:
*/
#include "data/data_folder.h"

#include "rabbit/rabbit_settings.h"
#include "rabbit/settings/rabbit_settings.h"
#include "data/data_session.h"
#include "data/data_channel.h"
#include "data/data_histories.h"
Expand Down
2 changes: 1 addition & 1 deletion Telegram/SourceFiles/data/data_peer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ For license and copyright information please follow this link:
*/
#include "data/data_peer.h"

#include "rabbit/rabbit_settings.h"
#include "rabbit/settings/rabbit_settings.h"
#include "data/data_user.h"
#include "data/data_chat.h"
#include "data/data_chat_participant_status.h"
Expand Down
2 changes: 1 addition & 1 deletion Telegram/SourceFiles/dialogs/dialogs_row.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ For license and copyright information please follow this link:
#include "history/history_item.h"
#include "lang/lang_keys.h"
#include "base/unixtime.h"
#include "rabbit/rabbit_settings.h"
#include "rabbit/settings/rabbit_settings.h"
#include "styles/style_dialogs.h"

namespace Dialogs {
Expand Down
2 changes: 1 addition & 1 deletion Telegram/SourceFiles/history/history_item_helpers.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ For license and copyright information please follow this link:
https://github.com/rabbitgramdesktop/rabbitgramdesktop/blob/dev/LEGAL
*/
#include "history/history_item_helpers.h"
#include "rabbit/rabbit_lang.h"
#include "rabbit/lang/rabbit_lang.h"

#include "api/api_text_entities.h"
#include "calls/calls_instance.h"
Expand Down
2 changes: 1 addition & 1 deletion Telegram/SourceFiles/history/history_widget.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ For license and copyright information please follow this link:
https://github.com/rabbitgramdesktop/rabbitgramdesktop/blob/dev/LEGAL
*/
#include "history/history_widget.h"
#include "rabbit/rabbit_settings.h"
#include "rabbit/settings/rabbit_settings.h"
#include <string>

#include "api/api_editing.h"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ For license and copyright information please follow this link:
https://github.com/rabbitgramdesktop/rabbitgramdesktop/blob/dev/LEGAL
*/
#include "history/view/history_view_context_menu.h"
#include "rabbit/rabbit_lang.h"
#include "rabbit/rabbit_settings.h"
#include "rabbit/lang/rabbit_lang.h"
#include "rabbit/settings/rabbit_settings.h"

#include "api/api_attached_stickers.h"
#include "api/api_editing.h"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ For license and copyright information please follow this link:
#include "calls/group/calls_group_call.h"
#include "calls/calls_instance.h"
#include "core/application.h"
#include "rabbit/rabbit_settings.h"
#include "rabbit/settings/rabbit_settings.h"
#include "styles/style_chat.h"
#include "styles/style_chat_helpers.h"

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ For license and copyright information please follow this link:
*/
#include "history/view/media/history_view_contact.h"

#include "rabbit/rabbit_settings.h"
#include "rabbit/settings/rabbit_settings.h"
#include "core/click_handler_types.h" // ClickHandlerContext
#include "lang/lang_keys.h"
#include "layout/layout_selection.h"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ For license and copyright information please follow this link:
https://github.com/rabbitgramdesktop/rabbitgramdesktop/blob/dev/LEGAL
*/
#include "history/view/media/history_view_media_unwrapped.h"
#include "rabbit/rabbit_settings.h"
#include "rabbit/settings/rabbit_settings.h"

#include "data/data_session.h"
#include "history/history.h"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ For license and copyright information please follow this link:
#include "main/main_session.h"
#include "apiwrap.h"
#include "api/api_polls.h"
#include "rabbit/rabbit_settings.h"
#include "rabbit/settings/rabbit_settings.h"
#include "styles/style_chat.h"
#include "styles/style_widgets.h"
#include "styles/style_window.h"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ For license and copyright information please follow this link:
https://github.com/rabbitgramdesktop/rabbitgramdesktop/blob/dev/LEGAL
*/
#include "history/view/media/history_view_sticker.h"
#include "rabbit/rabbit_settings.h"
#include "rabbit/settings/rabbit_settings.h"

#include "boxes/sticker_set_box.h"
#include "history/history.h"
Expand Down
4 changes: 2 additions & 2 deletions Telegram/SourceFiles/info/profile/info_profile_actions.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ For license and copyright information please follow this link:
https://github.com/rabbitgramdesktop/rabbitgramdesktop/blob/dev/LEGAL
*/
#include "info/profile/info_profile_actions.h"
#include "rabbit/rabbit_lang.h"
#include "rabbit/rabbit_settings.h"
#include "rabbit/lang/rabbit_lang.h"
#include "rabbit/settings/rabbit_settings.h"

#include "base/options.h"
#include "data/data_peer_values.h"
Expand Down
4 changes: 2 additions & 2 deletions Telegram/SourceFiles/info/profile/info_profile_values.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ For license and copyright information please follow this link:
https://github.com/rabbitgramdesktop/rabbitgramdesktop/blob/dev/LEGAL
*/
#include "info/profile/info_profile_values.h"
#include "rabbit/rabbit_settings.h"
#include "rabbit/rabbit_lang.h"
#include "rabbit/settings/rabbit_settings.h"
#include "rabbit/lang/rabbit_lang.h"

#include "info/profile/info_profile_badge.h"
#include "core/application.h"
Expand Down
2 changes: 1 addition & 1 deletion Telegram/SourceFiles/intro/intro_start.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ For license and copyright information please follow this link:
https://github.com/rabbitgramdesktop/rabbitgramdesktop/blob/dev/LEGAL
*/
#include "intro/intro_start.h"
#include "rabbit/rabbit_lang.h"
#include "rabbit/lang/rabbit_lang.h"

#include "lang/lang_keys.h"
#include "intro/intro_qr.h"
Expand Down
2 changes: 1 addition & 1 deletion Telegram/SourceFiles/intro/intro_widget.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ For license and copyright information please follow this link:
https://github.com/rabbitgramdesktop/rabbitgramdesktop/blob/dev/LEGAL
*/
#include "intro/intro_widget.h"
#include "rabbit/rabbit_lang.h"
#include "rabbit/lang/rabbit_lang.h"

#include "intro/intro_start.h"
#include "intro/intro_phone.h"
Expand Down
2 changes: 1 addition & 1 deletion Telegram/SourceFiles/mainwindow.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ For license and copyright information please follow this link:
https://github.com/rabbitgramdesktop/rabbitgramdesktop/blob/dev/LEGAL
*/
#include "mainwindow.h"
#include "rabbit/rabbit_lang.h"
#include "rabbit/lang/rabbit_lang.h"

#include "data/data_document.h"
#include "data/data_session.h"
Expand Down
10 changes: 10 additions & 0 deletions Telegram/SourceFiles/platform/win/tray_win.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@ For license and copyright information please follow this link:
*/
#include "platform/win/tray_win.h"

#include "rabbit/ui/rabbit_assets.h"

#include "base/invoke_queued.h"
#include "base/qt_signal_producer.h"
#include "core/application.h"
Expand Down Expand Up @@ -116,6 +118,14 @@ constexpr auto kTooltipDelay = crl::time(10000);
static auto ScaledLogoNoMargin = base::flat_map<int, QImage>();
static auto ScaledLogoDark = base::flat_map<int, QImage>();
static auto ScaledLogoLight = base::flat_map<int, QImage>();
static auto lastUsedIcon = currentAppLogoName();

if (lastUsedIcon != currentAppLogoName()) {
ScaledLogo = base::flat_map<int, QImage>();
ScaledLogoNoMargin = base::flat_map<int, QImage>();
ScaledLogoDark = base::flat_map<int, QImage>();
ScaledLogoLight = base::flat_map<int, QImage>();
}

const auto darkMode = IsDarkTaskbar();
auto &scaled = (monochrome && darkMode)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ the unofficial app based on Telegram Desktop.
For license and copyright information please follow this link:
https://github.com/rabbitgramdesktop/rabbitgramdesktop/blob/dev/LEGAL
*/
#include "rabbit/rabbit_lang.h"
#include "rabbit/lang/rabbit_lang.h"

#include "base/parse_helper.h"
#include "lang/lang_tag.h"
Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion Telegram/SourceFiles/rabbit/rabbit_version.h
Original file line number Diff line number Diff line change
Expand Up @@ -9,4 +9,4 @@ For license and copyright information please follow this link:

constexpr auto AppRabbitVersion = 4011008;
constexpr auto AppRabbitVersionStr = "4.11.8";
constexpr auto AppRabbitBetaVersion = false;
constexpr auto AppRabbitBetaVersion = false;
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ the unofficial app based on Telegram Desktop.
For license and copyright information please follow this link:
https://github.com/rabbitgramdesktop/rabbitgramdesktop/blob/dev/LEGAL
*/
#include "rabbit/rabbit_settings.h"
#include "rabbit/settings/rabbit_settings.h"

#include "rabbit/rabbit_version.h"
#include "mainwindow.h"
Expand Down Expand Up @@ -239,6 +239,9 @@ const std::map<QString, Definition, std::greater<QString>> DefinitionMap {
.type = SettingType::BoolSetting,
.defaultValue = false, }},
// Appearance
{ "app_icon", {
.type = SettingType::QStringSetting,
.defaultValue = DEFAULT_ICON, }},
{ "userpic_roundness", {
.type = SettingType::IntSetting,
.defaultValue = 50,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,15 @@ For license and copyright information please follow this link:
#include <QtCore/QJsonArray>

namespace RabbitSettings {

const auto DEFAULT_ICON = QString("default");
const auto ANGEL_ICON = QString("angel");
const auto COLOR_ICON = QString("color");
const auto IMPOSTOR_ICON = QString("impostor");
const auto MATRIX_ICON = QString("matrix");
const auto MOON_ICON = QString("moon");
const auto OLD_ICON = QString("old");

namespace JsonSettings {

void Start();
Expand Down Expand Up @@ -112,4 +121,4 @@ inline QJsonArray GetJsonArrayWithPending(
}

} // namespace JsonSettings
} // namespace RabbitSettings
} // namespace RabbitSettings
Loading

0 comments on commit fcdda7e

Please sign in to comment.