diff --git a/Telegram/CMakeLists.txt b/Telegram/CMakeLists.txt index 91f9a4bed..7d51f89c0 100644 --- a/Telegram/CMakeLists.txt +++ b/Telegram/CMakeLists.txt @@ -149,8 +149,13 @@ set(ayugram_files ayu/libs/sqlite/sqlite3.c ayu/libs/sqlite/sqlite3.h ayu/libs/sqlite/sqlite_orm.h - ayu/features/streamer_mode/streamer_mode_windows.cpp - ayu/features/streamer_mode/streamer_mode_linux.cpp + ayu/features/streamer_mode/platform/streamer_mode_win.cpp + ayu/features/streamer_mode/platform/streamer_mode_win.h + ayu/features/streamer_mode/platform/streamer_mode_linux.cpp + ayu/features/streamer_mode/platform/streamer_mode_linux.h + ayu/features/streamer_mode/platform/streamer_mode_mac.cpp + ayu/features/streamer_mode/platform/streamer_mode_mac.h + ayu/features/streamer_mode/streamer_mode.cpp ayu/features/streamer_mode/streamer_mode.h ayu/features/messageshot/message_shot.cpp ayu/features/messageshot/message_shot.h diff --git a/Telegram/Resources/art/ayu/alt/app_macos.png b/Telegram/Resources/art/ayu/alt/app_macos.png new file mode 100644 index 000000000..cc3ede0f9 Binary files /dev/null and b/Telegram/Resources/art/ayu/alt/app_macos.png differ diff --git a/Telegram/Resources/art/ayu/bard/app_macos.png b/Telegram/Resources/art/ayu/bard/app_macos.png new file mode 100644 index 000000000..9c6c6021f Binary files /dev/null and b/Telegram/Resources/art/ayu/bard/app_macos.png differ diff --git a/Telegram/Resources/art/ayu/chibi/app_macos.png b/Telegram/Resources/art/ayu/chibi/app_macos.png new file mode 100644 index 000000000..b2a0b8c8c Binary files /dev/null and b/Telegram/Resources/art/ayu/chibi/app_macos.png differ diff --git a/Telegram/Resources/art/ayu/chibi2/app_macos.png b/Telegram/Resources/art/ayu/chibi2/app_macos.png new file mode 100644 index 000000000..9cb258ecf Binary files /dev/null and b/Telegram/Resources/art/ayu/chibi2/app_macos.png differ diff --git a/Telegram/Resources/art/ayu/default/app_macos.png b/Telegram/Resources/art/ayu/default/app_macos.png new file mode 100644 index 000000000..16e428450 Binary files /dev/null and b/Telegram/Resources/art/ayu/default/app_macos.png differ diff --git a/Telegram/Resources/art/ayu/discord/app_macos.png b/Telegram/Resources/art/ayu/discord/app_macos.png new file mode 100644 index 000000000..0a7b8ff30 Binary files /dev/null and b/Telegram/Resources/art/ayu/discord/app_macos.png differ diff --git a/Telegram/Resources/art/ayu/extera/app_macos.png b/Telegram/Resources/art/ayu/extera/app_macos.png new file mode 100644 index 000000000..a052dd338 Binary files /dev/null and b/Telegram/Resources/art/ayu/extera/app_macos.png differ diff --git a/Telegram/Resources/art/ayu/macos/app.png b/Telegram/Resources/art/ayu/macos/app.png new file mode 100644 index 000000000..37f2d8b0f Binary files /dev/null and b/Telegram/Resources/art/ayu/macos/app.png differ diff --git a/Telegram/Resources/art/ayu/macos/app_icon.ico b/Telegram/Resources/art/ayu/macos/app_icon.ico new file mode 100644 index 000000000..bcf777a77 Binary files /dev/null and b/Telegram/Resources/art/ayu/macos/app_icon.ico differ diff --git a/Telegram/Resources/art/ayu/macos/app_macos.png b/Telegram/Resources/art/ayu/macos/app_macos.png new file mode 100644 index 000000000..5f9b8bf29 Binary files /dev/null and b/Telegram/Resources/art/ayu/macos/app_macos.png differ diff --git a/Telegram/Resources/art/ayu/macos/app_preview.png b/Telegram/Resources/art/ayu/macos/app_preview.png new file mode 100644 index 000000000..1513506fe Binary files /dev/null and b/Telegram/Resources/art/ayu/macos/app_preview.png differ diff --git a/Telegram/Resources/art/ayu/nothing/app_macos.png b/Telegram/Resources/art/ayu/nothing/app_macos.png new file mode 100644 index 000000000..ccf12fc0c Binary files /dev/null and b/Telegram/Resources/art/ayu/nothing/app_macos.png differ diff --git a/Telegram/Resources/art/ayu/spotify/app_macos.png b/Telegram/Resources/art/ayu/spotify/app_macos.png new file mode 100644 index 000000000..c43b93ded Binary files /dev/null and b/Telegram/Resources/art/ayu/spotify/app_macos.png differ diff --git a/Telegram/Resources/art/ayu/win95/app_macos.png b/Telegram/Resources/art/ayu/win95/app_macos.png new file mode 100644 index 000000000..040720dbe Binary files /dev/null and b/Telegram/Resources/art/ayu/win95/app_macos.png differ diff --git a/Telegram/Resources/art/ayu/yaplus/app_macos.png b/Telegram/Resources/art/ayu/yaplus/app_macos.png new file mode 100644 index 000000000..353bb0a4b Binary files /dev/null and b/Telegram/Resources/art/ayu/yaplus/app_macos.png differ diff --git a/Telegram/Resources/qrc/ayu/ayu.qrc b/Telegram/Resources/qrc/ayu/ayu.qrc index 7f25fa6a5..5b81520a8 100644 --- a/Telegram/Resources/qrc/ayu/ayu.qrc +++ b/Telegram/Resources/qrc/ayu/ayu.qrc @@ -2,36 +2,51 @@ ../../art/ayu/alt/app.png ../../art/ayu/alt/app_preview.png + ../../art/ayu/alt/app_macos.png ../../art/ayu/alt/app_icon.ico ../../art/ayu/bard/app.png ../../art/ayu/bard/app_preview.png + ../../art/ayu/bard/app_macos.png ../../art/ayu/bard/app_icon.ico ../../art/ayu/chibi/app.png ../../art/ayu/chibi/app_preview.png + ../../art/ayu/chibi/app_macos.png ../../art/ayu/chibi/app_icon.ico ../../art/ayu/chibi2/app.png ../../art/ayu/chibi2/app_preview.png + ../../art/ayu/chibi2/app_macos.png ../../art/ayu/chibi2/app_icon.ico ../../art/ayu/default/app.png ../../art/ayu/default/app_preview.png + ../../art/ayu/default/app_macos.png ../../art/ayu/default/app_icon.ico ../../art/ayu/discord/app.png ../../art/ayu/discord/app_preview.png + ../../art/ayu/discord/app_macos.png ../../art/ayu/discord/app_icon.ico ../../art/ayu/extera/app.png ../../art/ayu/extera/app_preview.png + ../../art/ayu/extera/app_macos.png ../../art/ayu/extera/app_icon.ico + ../../art/ayu/macos/app.png + ../../art/ayu/macos/app_preview.png + ../../art/ayu/macos/app_macos.png + ../../art/ayu/macos/app_icon.ico ../../art/ayu/nothing/app.png ../../art/ayu/nothing/app_preview.png + ../../art/ayu/nothing/app_macos.png ../../art/ayu/nothing/app_icon.ico ../../art/ayu/spotify/app.png ../../art/ayu/spotify/app_preview.png + ../../art/ayu/spotify/app_macos.png ../../art/ayu/spotify/app_icon.ico ../../art/ayu/win95/app.png ../../art/ayu/win95/app_preview.png + ../../art/ayu/win95/app_macos.png ../../art/ayu/win95/app_icon.ico ../../art/ayu/yaplus/app.png ../../art/ayu/yaplus/app_preview.png + ../../art/ayu/yaplus/app_macos.png ../../art/ayu/yaplus/app_icon.ico diff --git a/Telegram/SourceFiles/ayu/ayu_settings.cpp b/Telegram/SourceFiles/ayu/ayu_settings.cpp index f5cc5cfd6..b3837ec90 100644 --- a/Telegram/SourceFiles/ayu/ayu_settings.cpp +++ b/Telegram/SourceFiles/ayu/ayu_settings.cpp @@ -226,7 +226,13 @@ AyuGramSettings::AyuGramSettings() { localPremium = false; // ~ Customization - appIcon = AyuAssets::DEFAULT_ICON; + appIcon = +#ifdef Q_OS_DARWIN + AyuAssets::DEFAULT_MACOS_ICON +#else + AyuAssets::DEFAULT_ICON +#endif + ; simpleQuotesAndReplies = true; deletedMark = "🧹"; editedMark = Core::IsAppLaunched() ? tr::lng_edited(tr::now) : QString("edited"); diff --git a/Telegram/SourceFiles/ayu/data/ayu_database.cpp b/Telegram/SourceFiles/ayu/data/ayu_database.cpp index 562fbffb2..5222fdac8 100644 --- a/Telegram/SourceFiles/ayu/data/ayu_database.cpp +++ b/Telegram/SourceFiles/ayu/data/ayu_database.cpp @@ -4,7 +4,7 @@ // but be respectful and credit the original author. // // Copyright @Radolyn, 2024 -#include "ayu_database.h" +#include "ayu/data/ayu_database.h" #include @@ -137,18 +137,16 @@ namespace AyuDatabase { void moveCurrentDatabase() { auto time = base::unixtime::now(); - if (std::filesystem::exists("./tdata/ayudata.db")) { - std::filesystem::rename("./tdata/ayudata.db", QString("./tdata/ayudata_%1.db").arg(time).toStdString()); + if (QFile::exists("./tdata/ayudata.db")) { + QFile::rename("./tdata/ayudata.db", QString("./tdata/ayudata_%1.db").arg(time)); } - if (std::filesystem::exists("./tdata/ayudata.db-shm")) { - std::filesystem::rename("./tdata/ayudata.db-shm", - QString("./tdata/ayudata_%1.db-shm").arg(time).toStdString()); + if (QFile::exists("./tdata/ayudata.db-shm")) { + QFile::rename("./tdata/ayudata.db-shm", QString("./tdata/ayudata_%1.db-shm").arg(time)); } - if (std::filesystem::exists("./tdata/ayudata.db-wal")) { - std::filesystem::rename("./tdata/ayudata.db-wal", - QString("./tdata/ayudata_%1.db-wal").arg(time).toStdString()); + if (QFile::exists("./tdata/ayudata.db-wal")) { + QFile::rename("./tdata/ayudata.db-wal", QString("./tdata/ayudata_%1.db-wal").arg(time)); } } diff --git a/Telegram/SourceFiles/ayu/data/messages_storage.cpp b/Telegram/SourceFiles/ayu/data/messages_storage.cpp index 55b46d1fa..483574197 100644 --- a/Telegram/SourceFiles/ayu/data/messages_storage.cpp +++ b/Telegram/SourceFiles/ayu/data/messages_storage.cpp @@ -4,7 +4,7 @@ // but be respectful and credit the original author. // // Copyright @Radolyn, 2024 -#include "messages_storage.h" +#include "ayu/data/messages_storage.h" #include "ayu/ayu_constants.h" #include "ayu/data/ayu_database.h" diff --git a/Telegram/SourceFiles/ayu/features/streamer_mode/streamer_mode_linux.cpp b/Telegram/SourceFiles/ayu/features/streamer_mode/platform/streamer_mode_linux.cpp similarity index 56% rename from Telegram/SourceFiles/ayu/features/streamer_mode/streamer_mode_linux.cpp rename to Telegram/SourceFiles/ayu/features/streamer_mode/platform/streamer_mode_linux.cpp index 118a8b2e4..5786758ce 100644 --- a/Telegram/SourceFiles/ayu/features/streamer_mode/streamer_mode_linux.cpp +++ b/Telegram/SourceFiles/ayu/features/streamer_mode/platform/streamer_mode_linux.cpp @@ -5,31 +5,18 @@ // // Copyright @Radolyn, 2024 -#ifndef WIN32 +#include "ayu/features/streamer_mode/platform/streamer_mode_linux.h" -#include "streamer_mode.h" - -#include "core/application.h" #include "window/window_controller.h" -namespace AyuFeatures::StreamerMode -{ +namespace AyuFeatures::StreamerMode::Impl { -bool isEnabledVal; +void enableHook() { -bool isEnabled() -{ - return isEnabledVal; } -void enable() -{ - isEnabledVal = true; -} +void disableHook() { -void disable() -{ - isEnabledVal = false; } void hideWidgetWindow(QWidget *widget) @@ -43,5 +30,3 @@ void showWidgetWindow(QWidget *widget) } } - -#endif diff --git a/Telegram/SourceFiles/ayu/features/streamer_mode/platform/streamer_mode_linux.h b/Telegram/SourceFiles/ayu/features/streamer_mode/platform/streamer_mode_linux.h new file mode 100644 index 000000000..b7456d235 --- /dev/null +++ b/Telegram/SourceFiles/ayu/features/streamer_mode/platform/streamer_mode_linux.h @@ -0,0 +1,10 @@ +#pragma once + +namespace AyuFeatures::StreamerMode::Impl { + +void enableHook(); +void disableHook(); +void hideWidgetWindow(QWidget *widget); +void showWidgetWindow(QWidget *widget); + +} \ No newline at end of file diff --git a/Telegram/SourceFiles/ayu/features/streamer_mode/platform/streamer_mode_mac.cpp b/Telegram/SourceFiles/ayu/features/streamer_mode/platform/streamer_mode_mac.cpp new file mode 100644 index 000000000..ba45dd990 --- /dev/null +++ b/Telegram/SourceFiles/ayu/features/streamer_mode/platform/streamer_mode_mac.cpp @@ -0,0 +1,32 @@ +// This is the source code of AyuGram for Desktop. +// +// We do not and cannot prevent the use of our code, +// but be respectful and credit the original author. +// +// Copyright @Radolyn, 2024 + +#include "ayu/features/streamer_mode/platform/streamer_mode_mac.h" + +#include "window/window_controller.h" + +namespace AyuFeatures::StreamerMode::Impl { + +void enableHook() { + +} + +void disableHook() { + +} + +void hideWidgetWindow(QWidget *widget) +{ + +} + +void showWidgetWindow(QWidget *widget) +{ + +} + +} diff --git a/Telegram/SourceFiles/ayu/features/streamer_mode/platform/streamer_mode_mac.h b/Telegram/SourceFiles/ayu/features/streamer_mode/platform/streamer_mode_mac.h new file mode 100644 index 000000000..b7456d235 --- /dev/null +++ b/Telegram/SourceFiles/ayu/features/streamer_mode/platform/streamer_mode_mac.h @@ -0,0 +1,10 @@ +#pragma once + +namespace AyuFeatures::StreamerMode::Impl { + +void enableHook(); +void disableHook(); +void hideWidgetWindow(QWidget *widget); +void showWidgetWindow(QWidget *widget); + +} \ No newline at end of file diff --git a/Telegram/SourceFiles/ayu/features/streamer_mode/streamer_mode_windows.cpp b/Telegram/SourceFiles/ayu/features/streamer_mode/platform/streamer_mode_win.cpp similarity index 74% rename from Telegram/SourceFiles/ayu/features/streamer_mode/streamer_mode_windows.cpp rename to Telegram/SourceFiles/ayu/features/streamer_mode/platform/streamer_mode_win.cpp index 600394fa6..c600f7c6e 100644 --- a/Telegram/SourceFiles/ayu/features/streamer_mode/streamer_mode_windows.cpp +++ b/Telegram/SourceFiles/ayu/features/streamer_mode/platform/streamer_mode_win.cpp @@ -5,41 +5,25 @@ // // Copyright @Radolyn, 2024 -#ifdef WIN32 - -#include "streamer_mode.h" +#include "ayu/features/streamer_mode/platform/streamer_mode_win.h" #include "core/application.h" #include "window/window_controller.h" -namespace AyuFeatures::StreamerMode { +namespace AyuFeatures::StreamerMode::Impl { -bool isEnabledVal; - -bool isEnabled() { - return isEnabledVal; -} - -void enable() { +void enableHook() { auto handle = Core::App().activeWindow()->widget()->psHwnd(); - SetWindowDisplayAffinity(handle, WDA_EXCLUDEFROMCAPTURE); - Core::App().enumerateWindows([&](not_null w) { SetWindowDisplayAffinity(w->widget()->psHwnd(), WDA_EXCLUDEFROMCAPTURE); }); - - isEnabledVal = true; } -void disable() { +void disableHook() { auto handle = Core::App().activeWindow()->widget()->psHwnd(); - SetWindowDisplayAffinity(handle, WDA_NONE); - Core::App().enumerateWindows([&](not_null w) { SetWindowDisplayAffinity(w->widget()->psHwnd(), WDA_NONE); }); - - isEnabledVal = false; } void hideWidgetWindow(QWidget *widget) { @@ -53,5 +37,3 @@ void showWidgetWindow(QWidget *widget) { } } - -#endif diff --git a/Telegram/SourceFiles/ayu/features/streamer_mode/platform/streamer_mode_win.h b/Telegram/SourceFiles/ayu/features/streamer_mode/platform/streamer_mode_win.h new file mode 100644 index 000000000..b7456d235 --- /dev/null +++ b/Telegram/SourceFiles/ayu/features/streamer_mode/platform/streamer_mode_win.h @@ -0,0 +1,10 @@ +#pragma once + +namespace AyuFeatures::StreamerMode::Impl { + +void enableHook(); +void disableHook(); +void hideWidgetWindow(QWidget *widget); +void showWidgetWindow(QWidget *widget); + +} \ No newline at end of file diff --git a/Telegram/SourceFiles/ayu/features/streamer_mode/streamer_mode.cpp b/Telegram/SourceFiles/ayu/features/streamer_mode/streamer_mode.cpp new file mode 100644 index 000000000..016aa0a38 --- /dev/null +++ b/Telegram/SourceFiles/ayu/features/streamer_mode/streamer_mode.cpp @@ -0,0 +1,52 @@ +// This is the source code of AyuGram for Desktop. +// +// We do not and cannot prevent the use of our code, +// but be respectful and credit the original author. +// +// Copyright @Radolyn, 2024 + +#include "streamer_mode.h" + +#include "window/window_controller.h" + +#if defined Q_OS_WINRT || defined Q_OS_WIN +#include "ayu/features/streamer_mode/platform/streamer_mode_win.h" +#elif defined Q_OS_MAC // Q_OS_WINRT || Q_OS_WIN +#include "ayu/features/streamer_mode/platform/streamer_mode_mac.h" +#else // Q_OS_WINRT || Q_OS_WIN || Q_OS_MAC +#include "ayu/features/streamer_mode/platform/streamer_mode_linux.h" +#endif // else for Q_OS_WINRT || Q_OS_WIN || Q_OS_MAC + +namespace AyuFeatures::StreamerMode +{ + +bool isEnabledVal; + +bool isEnabled() +{ + return isEnabledVal; +} + +void enable() +{ + isEnabledVal = true; + Impl::enableHook(); +} + +void disable() +{ + isEnabledVal = false; + Impl::disableHook(); +} + +void hideWidgetWindow(QWidget *widget) +{ + Impl::hideWidgetWindow(widget); +} + +void showWidgetWindow(QWidget *widget) +{ + Impl::showWidgetWindow(widget); +} + +} diff --git a/Telegram/SourceFiles/ayu/ui/ayu_logo.cpp b/Telegram/SourceFiles/ayu/ui/ayu_logo.cpp index 476100a59..a84e0e1d7 100644 --- a/Telegram/SourceFiles/ayu/ui/ayu_logo.cpp +++ b/Telegram/SourceFiles/ayu/ui/ayu_logo.cpp @@ -34,7 +34,11 @@ void loadIcons() { if (LAST_LOADED_NAME != settings->appIcon) { LAST_LOADED_NAME = settings->appIcon; +#ifdef Q_OS_DARWIN + LAST_LOADED = QImage(qsl(":/gui/art/ayu/%1/app_macos.png").arg(settings->appIcon)); +#else LAST_LOADED = QImage(qsl(":/gui/art/ayu/%1/app.png").arg(settings->appIcon)); +#endif LAST_LOADED_NO_MARGIN = QImage(qsl(":/gui/art/ayu/%1/app_preview.png").arg(settings->appIcon)); } } diff --git a/Telegram/SourceFiles/ayu/ui/ayu_logo.h b/Telegram/SourceFiles/ayu/ui/ayu_logo.h index 4049fbe38..80aded10c 100644 --- a/Telegram/SourceFiles/ayu/ui/ayu_logo.h +++ b/Telegram/SourceFiles/ayu/ui/ayu_logo.h @@ -11,6 +11,7 @@ namespace AyuAssets { ICON(DEFAULT, "default"); +ICON(DEFAULT_MACOS, "macos"); ICON(ALT, "alt"); ICON(DISCORD, "discord"); ICON(SPOTIFY, "spotify"); diff --git a/Telegram/SourceFiles/ayu/ui/settings/icon_picker.cpp b/Telegram/SourceFiles/ayu/ui/settings/icon_picker.cpp index 248781193..8e5b566fa 100644 --- a/Telegram/SourceFiles/ayu/ui/settings/icon_picker.cpp +++ b/Telegram/SourceFiles/ayu/ui/settings/icon_picker.cpp @@ -21,6 +21,9 @@ #endif const QVector icons{ +#ifdef Q_OS_DARWIN + AyuAssets::DEFAULT_MACOS_ICON, +#endif AyuAssets::DEFAULT_ICON, AyuAssets::ALT_ICON, AyuAssets::DISCORD_ICON, diff --git a/Telegram/Telegram/Images.xcassets/AppIcon.appiconset/icon128.png b/Telegram/Telegram/Images.xcassets/AppIcon.appiconset/icon128.png index 36d300faa..99f1f0a59 100644 Binary files a/Telegram/Telegram/Images.xcassets/AppIcon.appiconset/icon128.png and b/Telegram/Telegram/Images.xcassets/AppIcon.appiconset/icon128.png differ diff --git a/Telegram/Telegram/Images.xcassets/AppIcon.appiconset/icon128@2x.png b/Telegram/Telegram/Images.xcassets/AppIcon.appiconset/icon128@2x.png index cbb2420d3..6b9c8493e 100644 Binary files a/Telegram/Telegram/Images.xcassets/AppIcon.appiconset/icon128@2x.png and b/Telegram/Telegram/Images.xcassets/AppIcon.appiconset/icon128@2x.png differ diff --git a/Telegram/Telegram/Images.xcassets/AppIcon.appiconset/icon16.png b/Telegram/Telegram/Images.xcassets/AppIcon.appiconset/icon16.png index 0ba496798..6b55ad944 100644 Binary files a/Telegram/Telegram/Images.xcassets/AppIcon.appiconset/icon16.png and b/Telegram/Telegram/Images.xcassets/AppIcon.appiconset/icon16.png differ diff --git a/Telegram/Telegram/Images.xcassets/AppIcon.appiconset/icon16@2x.png b/Telegram/Telegram/Images.xcassets/AppIcon.appiconset/icon16@2x.png index 71066360e..0dfb8a6e5 100644 Binary files a/Telegram/Telegram/Images.xcassets/AppIcon.appiconset/icon16@2x.png and b/Telegram/Telegram/Images.xcassets/AppIcon.appiconset/icon16@2x.png differ diff --git a/Telegram/Telegram/Images.xcassets/AppIcon.appiconset/icon256.png b/Telegram/Telegram/Images.xcassets/AppIcon.appiconset/icon256.png index 38f1c1f4f..57fe07691 100644 Binary files a/Telegram/Telegram/Images.xcassets/AppIcon.appiconset/icon256.png and b/Telegram/Telegram/Images.xcassets/AppIcon.appiconset/icon256.png differ diff --git a/Telegram/Telegram/Images.xcassets/AppIcon.appiconset/icon256@2x.png b/Telegram/Telegram/Images.xcassets/AppIcon.appiconset/icon256@2x.png index 10d4b1b36..de262a24c 100644 Binary files a/Telegram/Telegram/Images.xcassets/AppIcon.appiconset/icon256@2x.png and b/Telegram/Telegram/Images.xcassets/AppIcon.appiconset/icon256@2x.png differ diff --git a/Telegram/Telegram/Images.xcassets/AppIcon.appiconset/icon32.png b/Telegram/Telegram/Images.xcassets/AppIcon.appiconset/icon32.png index ca84cd0e7..0dfb8a6e5 100644 Binary files a/Telegram/Telegram/Images.xcassets/AppIcon.appiconset/icon32.png and b/Telegram/Telegram/Images.xcassets/AppIcon.appiconset/icon32.png differ diff --git a/Telegram/Telegram/Images.xcassets/AppIcon.appiconset/icon32@2x.png b/Telegram/Telegram/Images.xcassets/AppIcon.appiconset/icon32@2x.png index 53f70ab9c..fe4be5360 100644 Binary files a/Telegram/Telegram/Images.xcassets/AppIcon.appiconset/icon32@2x.png and b/Telegram/Telegram/Images.xcassets/AppIcon.appiconset/icon32@2x.png differ diff --git a/Telegram/Telegram/Images.xcassets/AppIcon.appiconset/icon512.png b/Telegram/Telegram/Images.xcassets/AppIcon.appiconset/icon512.png index 7af9b445d..de262a24c 100644 Binary files a/Telegram/Telegram/Images.xcassets/AppIcon.appiconset/icon512.png and b/Telegram/Telegram/Images.xcassets/AppIcon.appiconset/icon512.png differ diff --git a/Telegram/Telegram/Images.xcassets/AppIcon.appiconset/icon512@2x.png b/Telegram/Telegram/Images.xcassets/AppIcon.appiconset/icon512@2x.png index 708cfb8cc..f1b39c220 100644 Binary files a/Telegram/Telegram/Images.xcassets/AppIcon.appiconset/icon512@2x.png and b/Telegram/Telegram/Images.xcassets/AppIcon.appiconset/icon512@2x.png differ diff --git a/Telegram/Telegram/Images.xcassets/Icon.iconset/icon_128x128.png b/Telegram/Telegram/Images.xcassets/Icon.iconset/icon_128x128.png index 36d300faa..99f1f0a59 100644 Binary files a/Telegram/Telegram/Images.xcassets/Icon.iconset/icon_128x128.png and b/Telegram/Telegram/Images.xcassets/Icon.iconset/icon_128x128.png differ diff --git a/Telegram/Telegram/Images.xcassets/Icon.iconset/icon_128x128@2x.png b/Telegram/Telegram/Images.xcassets/Icon.iconset/icon_128x128@2x.png index cbb2420d3..57fe07691 100644 Binary files a/Telegram/Telegram/Images.xcassets/Icon.iconset/icon_128x128@2x.png and b/Telegram/Telegram/Images.xcassets/Icon.iconset/icon_128x128@2x.png differ diff --git a/Telegram/Telegram/Images.xcassets/Icon.iconset/icon_16x16.png b/Telegram/Telegram/Images.xcassets/Icon.iconset/icon_16x16.png index 0ba496798..6b55ad944 100644 Binary files a/Telegram/Telegram/Images.xcassets/Icon.iconset/icon_16x16.png and b/Telegram/Telegram/Images.xcassets/Icon.iconset/icon_16x16.png differ diff --git a/Telegram/Telegram/Images.xcassets/Icon.iconset/icon_16x16@2x.png b/Telegram/Telegram/Images.xcassets/Icon.iconset/icon_16x16@2x.png index 71066360e..0dfb8a6e5 100644 Binary files a/Telegram/Telegram/Images.xcassets/Icon.iconset/icon_16x16@2x.png and b/Telegram/Telegram/Images.xcassets/Icon.iconset/icon_16x16@2x.png differ diff --git a/Telegram/Telegram/Images.xcassets/Icon.iconset/icon_256x256.png b/Telegram/Telegram/Images.xcassets/Icon.iconset/icon_256x256.png index 38f1c1f4f..57fe07691 100644 Binary files a/Telegram/Telegram/Images.xcassets/Icon.iconset/icon_256x256.png and b/Telegram/Telegram/Images.xcassets/Icon.iconset/icon_256x256.png differ diff --git a/Telegram/Telegram/Images.xcassets/Icon.iconset/icon_256x256@2x.png b/Telegram/Telegram/Images.xcassets/Icon.iconset/icon_256x256@2x.png index 10d4b1b36..de262a24c 100644 Binary files a/Telegram/Telegram/Images.xcassets/Icon.iconset/icon_256x256@2x.png and b/Telegram/Telegram/Images.xcassets/Icon.iconset/icon_256x256@2x.png differ diff --git a/Telegram/Telegram/Images.xcassets/Icon.iconset/icon_32x32.png b/Telegram/Telegram/Images.xcassets/Icon.iconset/icon_32x32.png index ca84cd0e7..0dfb8a6e5 100644 Binary files a/Telegram/Telegram/Images.xcassets/Icon.iconset/icon_32x32.png and b/Telegram/Telegram/Images.xcassets/Icon.iconset/icon_32x32.png differ diff --git a/Telegram/Telegram/Images.xcassets/Icon.iconset/icon_32x32@2x.png b/Telegram/Telegram/Images.xcassets/Icon.iconset/icon_32x32@2x.png index 53f70ab9c..fe4be5360 100644 Binary files a/Telegram/Telegram/Images.xcassets/Icon.iconset/icon_32x32@2x.png and b/Telegram/Telegram/Images.xcassets/Icon.iconset/icon_32x32@2x.png differ diff --git a/Telegram/Telegram/Images.xcassets/Icon.iconset/icon_512x512.png b/Telegram/Telegram/Images.xcassets/Icon.iconset/icon_512x512.png index 7af9b445d..de262a24c 100644 Binary files a/Telegram/Telegram/Images.xcassets/Icon.iconset/icon_512x512.png and b/Telegram/Telegram/Images.xcassets/Icon.iconset/icon_512x512.png differ diff --git a/Telegram/Telegram/Images.xcassets/Icon.iconset/icon_512x512@2x.png b/Telegram/Telegram/Images.xcassets/Icon.iconset/icon_512x512@2x.png index 708cfb8cc..f1b39c220 100644 Binary files a/Telegram/Telegram/Images.xcassets/Icon.iconset/icon_512x512@2x.png and b/Telegram/Telegram/Images.xcassets/Icon.iconset/icon_512x512@2x.png differ diff --git a/docs/building-mac.md b/docs/building-mac.md new file mode 100644 index 000000000..b66847dad --- /dev/null +++ b/docs/building-mac.md @@ -0,0 +1,25 @@ +## Build instructions for macOS + +### Prepare folder + +Choose a folder for the future build, for example **/Users/user/TBuild**. It will be named ***BuildPath*** in the rest of this document. All commands will be launched from Terminal. + +### Clone source code and prepare libraries + +Go to ***BuildPath*** and run + + /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)" + brew install git automake cmake wget pkg-config gnu-tar ninja nasm meson + + sudo xcode-select -s /Applications/Xcode.app/Contents/Developer + + git clone --recursive https://github.com/AyuGram/AyuGramDesktop.git tdesktop + ./tdesktop/Telegram/build/prepare/mac.sh + +### Building the project + +Go to ***BuildPath*/tdesktop/Telegram** and run + + ./configure.sh -D TDESKTOP_API_ID=2040 -D TDESKTOP_API_HASH=b18441a1ff607e10a989891a5462e627 + +Then launch Xcode, open ***BuildPath*/tdesktop/out/Telegram.xcodeproj** and build for Debug / Release.