|
|
|
@ -1,6 +1,8 @@
|
|
|
|
|
find_package(Qt5 5.6 COMPONENTS Core Gui Widgets REQUIRED)
|
|
|
|
|
|
|
|
|
|
include_directories(${Qt5Core_INCLUDE_DIRS} ${Qt5Gui_INCLUDE_DIRS} ${Qt5Widgets_INCLUDE_DIRS})
|
|
|
|
|
include_directories(${Qt5Core_INCLUDE_DIRS} ${Qt5Core_PRIVATE_INCLUDE_DIRS})
|
|
|
|
|
include_directories(${Qt5Gui_INCLUDE_DIRS} ${Qt5Gui_PRIVATE_INCLUDE_DIRS})
|
|
|
|
|
include_directories(${Qt5Widgets_INCLUDE_DIRS} ${Qt5Widgets_PRIVATE_INCLUDE_DIRS})
|
|
|
|
|
|
|
|
|
|
# defines
|
|
|
|
|
if(CMAKE_SYSTEM_NAME STREQUAL "Linux")
|
|
|
|
@ -15,94 +17,73 @@ endif()
|
|
|
|
|
## Codegen Tools
|
|
|
|
|
##======================
|
|
|
|
|
|
|
|
|
|
set(codegen_common_SRC
|
|
|
|
|
SourceFiles/codegen/common/basic_tokenized_file.cpp
|
|
|
|
|
SourceFiles/codegen/common/checked_utf8_string.cpp
|
|
|
|
|
SourceFiles/codegen/common/clean_file.cpp
|
|
|
|
|
SourceFiles/codegen/common/cpp_file.cpp
|
|
|
|
|
SourceFiles/codegen/common/logging.cpp
|
|
|
|
|
)
|
|
|
|
|
|
|
|
|
|
add_library(codegen_common STATIC ${codegen_common_SRC})
|
|
|
|
|
qt5_use_modules(codegen_common Core)
|
|
|
|
|
|
|
|
|
|
##======================
|
|
|
|
|
|
|
|
|
|
set(codegen_style_SRC
|
|
|
|
|
SourceFiles/codegen/style/generator.cpp
|
|
|
|
|
SourceFiles/codegen/style/main.cpp
|
|
|
|
|
SourceFiles/codegen/style/module.cpp
|
|
|
|
|
SourceFiles/codegen/style/options.cpp
|
|
|
|
|
SourceFiles/codegen/style/parsed_file.cpp
|
|
|
|
|
SourceFiles/codegen/style/processor.cpp
|
|
|
|
|
SourceFiles/codegen/style/structure_types.cpp
|
|
|
|
|
)
|
|
|
|
|
|
|
|
|
|
add_executable(codegen_style ${codegen_style_SRC})
|
|
|
|
|
target_link_libraries(codegen_style codegen_common Qt5::Core Qt5::Gui)
|
|
|
|
|
qt5_use_modules(codegen_style Core Gui)
|
|
|
|
|
|
|
|
|
|
##======================
|
|
|
|
|
|
|
|
|
|
set(codegen_numbers_SRC
|
|
|
|
|
SourceFiles/codegen/numbers/generator.cpp
|
|
|
|
|
SourceFiles/codegen/numbers/main.cpp
|
|
|
|
|
SourceFiles/codegen/numbers/options.cpp
|
|
|
|
|
SourceFiles/codegen/numbers/parsed_file.cpp
|
|
|
|
|
SourceFiles/codegen/numbers/processor.cpp
|
|
|
|
|
)
|
|
|
|
|
|
|
|
|
|
add_executable(codegen_numbers ${codegen_numbers_SRC})
|
|
|
|
|
target_link_libraries(codegen_numbers codegen_common Qt5::Core)
|
|
|
|
|
qt5_use_modules(codegen_numbers Core)
|
|
|
|
|
|
|
|
|
|
##======================
|
|
|
|
|
|
|
|
|
|
set(MetaLang_SRC
|
|
|
|
|
SourceFiles/_other/mlmain.cpp
|
|
|
|
|
SourceFiles/_other/genlang.cpp
|
|
|
|
|
)
|
|
|
|
|
|
|
|
|
|
add_executable(MetaLang ${MetaLang_SRC})
|
|
|
|
|
target_link_libraries(MetaLang codegen_common Qt5::Core)
|
|
|
|
|
#qt5_use_modules(codegen_numbers Core)
|
|
|
|
|
|
|
|
|
|
##======================
|
|
|
|
|
include_directories(SourceFiles)
|
|
|
|
|
add_subdirectory(SourceFiles/codegen)
|
|
|
|
|
|
|
|
|
|
#-w<(PRODUCT_DIR)/../.. -- wtf is that
|
|
|
|
|
add_custom_command(
|
|
|
|
|
COMMENT "Generating palette"
|
|
|
|
|
OUTPUT
|
|
|
|
|
styles/palette.h
|
|
|
|
|
styles/palette.cpp
|
|
|
|
|
COMMAND
|
|
|
|
|
codegen_style -I${CMAKE_CURRENT_SOURCE_DIR}/Resources -I${CMAKE_CURRENT_SOURCE_DIR}
|
|
|
|
|
-o${CMAKE_CURRENT_BINARY_DIR}/styles -w${CMAKE_SOURCE_DIR}
|
|
|
|
|
colors.palette
|
|
|
|
|
OUTPUT
|
|
|
|
|
styles/palette.h
|
|
|
|
|
styles/palette.cpp
|
|
|
|
|
WORKING_DIRECTORY styles
|
|
|
|
|
MAIN_DEPENDENCY ${CMAKE_CURRENT_SOURCE_DIR}/Resources/colors.palette)
|
|
|
|
|
DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/Resources/colors.palette
|
|
|
|
|
MAIN_DEPENDENCY ${CMAKE_CURRENT_SOURCE_DIR}/Resources/colors.palette
|
|
|
|
|
)
|
|
|
|
|
|
|
|
|
|
add_custom_command(
|
|
|
|
|
COMMENT "Generating numbers"
|
|
|
|
|
COMMAND
|
|
|
|
|
codegen_numbers -o${CMAKE_CURRENT_BINARY_DIR} ${CMAKE_CURRENT_SOURCE_DIR}/Resources/numbers.txt
|
|
|
|
|
OUTPUT
|
|
|
|
|
numbers.h
|
|
|
|
|
numbers.cpp
|
|
|
|
|
COMMAND
|
|
|
|
|
codegen_numbers -o${CMAKE_CURRENT_BINARY_DIR} ${CMAKE_CURRENT_SOURCE_DIR}/Resources/numbers.txt
|
|
|
|
|
WORKING_DIRECTORY .
|
|
|
|
|
MAIN_DEPENDENCY ${CMAKE_CURRENT_SOURCE_DIR}/Resources/numbers.txt)
|
|
|
|
|
DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/Resources/numbers.txt
|
|
|
|
|
MAIN_DEPENDENCY ${CMAKE_CURRENT_SOURCE_DIR}/Resources/numbers.txt
|
|
|
|
|
)
|
|
|
|
|
|
|
|
|
|
add_custom_command(
|
|
|
|
|
COMMENT "Generating langs"
|
|
|
|
|
COMMAND
|
|
|
|
|
MetaLang
|
|
|
|
|
-lang_in ${CMAKE_CURRENT_SOURCE_DIR}/Resources/langs/lang.strings
|
|
|
|
|
-lang_out ${CMAKE_CURRENT_BINARY_DIR}/lang_auto
|
|
|
|
|
OUTPUT
|
|
|
|
|
lang_auto.h
|
|
|
|
|
lang_auto.cpp
|
|
|
|
|
COMMAND
|
|
|
|
|
codegen_lang -o${CMAKE_CURRENT_BINARY_DIR} -w${CMAKE_SOURCE_DIR} ${CMAKE_CURRENT_SOURCE_DIR}/Resources/langs/lang.strings
|
|
|
|
|
WORKING_DIRECTORY .
|
|
|
|
|
MAIN_DEPENDENCY ${CMAKE_CURRENT_SOURCE_DIR}/Resources/langs/lang.strings)
|
|
|
|
|
DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/Resources/langs/lang.strings
|
|
|
|
|
MAIN_DEPENDENCY ${CMAKE_CURRENT_SOURCE_DIR}/Resources/langs/lang.strings
|
|
|
|
|
)
|
|
|
|
|
|
|
|
|
|
add_custom_command(
|
|
|
|
|
COMMENT "Generating emoji"
|
|
|
|
|
OUTPUT
|
|
|
|
|
emoji.cpp
|
|
|
|
|
emoji.h
|
|
|
|
|
COMMAND
|
|
|
|
|
codegen_emoji -o${CMAKE_CURRENT_BINARY_DIR} -w${CMAKE_SOURCE_DIR}
|
|
|
|
|
WORKING_DIRECTORY .
|
|
|
|
|
DEPENDS
|
|
|
|
|
codegen_emoji
|
|
|
|
|
VERBATIM
|
|
|
|
|
)
|
|
|
|
|
|
|
|
|
|
add_custom_command(
|
|
|
|
|
COMMENT "Generating schema"
|
|
|
|
|
OUTPUT
|
|
|
|
|
scheme.cpp
|
|
|
|
|
scheme.h
|
|
|
|
|
COMMAND
|
|
|
|
|
python ${CMAKE_CURRENT_SOURCE_DIR}/SourceFiles/codegen/scheme/codegen_scheme.py -o${CMAKE_CURRENT_BINARY_DIR} ${CMAKE_CURRENT_SOURCE_DIR}/Resources/scheme.tl
|
|
|
|
|
WORKING_DIRECTORY .
|
|
|
|
|
DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/Resources/scheme.tl
|
|
|
|
|
MAIN_DEPENDENCY ${CMAKE_CURRENT_SOURCE_DIR}/Resources/scheme.tl
|
|
|
|
|
VERBATIM
|
|
|
|
|
)
|
|
|
|
|
|
|
|
|
|
##========
|
|
|
|
|
|
|
|
|
@ -117,7 +98,7 @@ list(APPEND style_files
|
|
|
|
|
SourceFiles/overview/overview
|
|
|
|
|
SourceFiles/profile/profile
|
|
|
|
|
SourceFiles/settings/settings
|
|
|
|
|
SourceFiles/stickers/stickers
|
|
|
|
|
SourceFiles/chat_helpers/chat_helpers
|
|
|
|
|
SourceFiles/ui/widgets/widgets
|
|
|
|
|
SourceFiles/window/window
|
|
|
|
|
)
|
|
|
|
@ -135,6 +116,8 @@ foreach (src ${style_files})
|
|
|
|
|
-I${CMAKE_CURRENT_SOURCE_DIR}/SourceFiles
|
|
|
|
|
-o${CMAKE_CURRENT_BINARY_DIR}/styles -w${CMAKE_SOURCE_DIR}
|
|
|
|
|
${CMAKE_CURRENT_SOURCE_DIR}/${src}.style
|
|
|
|
|
DEPENDS
|
|
|
|
|
${CMAKE_CURRENT_SOURCE_DIR}/${src}.style
|
|
|
|
|
MAIN_DEPENDENCY ${CMAKE_CURRENT_SOURCE_DIR}/${src}.style)
|
|
|
|
|
|
|
|
|
|
list(APPEND style_sources
|
|
|
|
@ -146,6 +129,8 @@ endforeach()
|
|
|
|
|
## Main app
|
|
|
|
|
##======================
|
|
|
|
|
|
|
|
|
|
add_subdirectory(SourceFiles/boxes)
|
|
|
|
|
|
|
|
|
|
# @fixme hardcoded path before I figure a way to include private Qt headers or remove
|
|
|
|
|
# this dependency on QtGui/private/qfontengine_p.h from sources
|
|
|
|
|
#include_directories(/usr/local/opt/qt5/lib/QtGui.framework/Versions/5/Headers/5.7.0/QtGui)
|
|
|
|
@ -154,69 +139,32 @@ set(APP_SRC
|
|
|
|
|
${CMAKE_CURRENT_BINARY_DIR}/styles/palette.cpp
|
|
|
|
|
${CMAKE_CURRENT_BINARY_DIR}/numbers.cpp
|
|
|
|
|
${CMAKE_CURRENT_BINARY_DIR}/lang_auto.cpp
|
|
|
|
|
${CMAKE_CURRENT_BINARY_DIR}/scheme.cpp
|
|
|
|
|
${CMAKE_CURRENT_BINARY_DIR}/emoji.cpp
|
|
|
|
|
${style_sources}
|
|
|
|
|
|
|
|
|
|
SourceFiles/apiwrap.cpp
|
|
|
|
|
SourceFiles/app.cpp
|
|
|
|
|
SourceFiles/application.cpp
|
|
|
|
|
SourceFiles/autoupdater.cpp
|
|
|
|
|
SourceFiles/dialogswidget.cpp
|
|
|
|
|
SourceFiles/facades.cpp
|
|
|
|
|
SourceFiles/fileuploader.cpp
|
|
|
|
|
SourceFiles/history.cpp
|
|
|
|
|
SourceFiles/historywidget.cpp
|
|
|
|
|
SourceFiles/lang.cpp
|
|
|
|
|
SourceFiles/langloaderplain.cpp
|
|
|
|
|
SourceFiles/layerwidget.cpp
|
|
|
|
|
SourceFiles/layout.cpp
|
|
|
|
|
SourceFiles/localimageloader.cpp
|
|
|
|
|
SourceFiles/localstorage.cpp
|
|
|
|
|
SourceFiles/logs.cpp
|
|
|
|
|
SourceFiles/main.cpp
|
|
|
|
|
SourceFiles/mainwidget.cpp
|
|
|
|
|
SourceFiles/mainwindow.cpp
|
|
|
|
|
SourceFiles/mediaview.cpp
|
|
|
|
|
SourceFiles/observer_peer.cpp
|
|
|
|
|
SourceFiles/overviewwidget.cpp
|
|
|
|
|
SourceFiles/passcodewidget.cpp
|
|
|
|
|
SourceFiles/settings.cpp
|
|
|
|
|
SourceFiles/shortcuts.cpp
|
|
|
|
|
SourceFiles/stdafx.cpp
|
|
|
|
|
SourceFiles/structs.cpp
|
|
|
|
|
SourceFiles/base/observer.cpp
|
|
|
|
|
SourceFiles/base/parse_helper.cpp
|
|
|
|
|
SourceFiles/base/qthelp_url.cpp
|
|
|
|
|
SourceFiles/base/runtime_composer.cpp
|
|
|
|
|
SourceFiles/base/task_queue.cpp
|
|
|
|
|
SourceFiles/base/timer.cpp
|
|
|
|
|
|
|
|
|
|
SourceFiles/boxes/aboutbox.cpp
|
|
|
|
|
SourceFiles/boxes/abstractbox.cpp
|
|
|
|
|
SourceFiles/boxes/addcontactbox.cpp
|
|
|
|
|
SourceFiles/boxes/autolockbox.cpp
|
|
|
|
|
SourceFiles/boxes/backgroundbox.cpp
|
|
|
|
|
SourceFiles/boxes/confirmbox.cpp
|
|
|
|
|
SourceFiles/boxes/confirmphonebox.cpp
|
|
|
|
|
SourceFiles/boxes/connectionbox.cpp
|
|
|
|
|
SourceFiles/boxes/contactsbox.cpp
|
|
|
|
|
SourceFiles/boxes/downloadpathbox.cpp
|
|
|
|
|
SourceFiles/boxes/emojibox.cpp
|
|
|
|
|
SourceFiles/boxes/languagebox.cpp
|
|
|
|
|
SourceFiles/boxes/localstoragebox.cpp
|
|
|
|
|
SourceFiles/boxes/members_box.cpp
|
|
|
|
|
SourceFiles/boxes/notifications_box.cpp
|
|
|
|
|
SourceFiles/boxes/passcodebox.cpp
|
|
|
|
|
SourceFiles/boxes/photocropbox.cpp
|
|
|
|
|
SourceFiles/boxes/report_box.cpp
|
|
|
|
|
SourceFiles/boxes/send_files_box.cpp
|
|
|
|
|
SourceFiles/boxes/sessionsbox.cpp
|
|
|
|
|
SourceFiles/boxes/sharebox.cpp
|
|
|
|
|
SourceFiles/boxes/stickers_box.cpp
|
|
|
|
|
SourceFiles/boxes/stickersetbox.cpp
|
|
|
|
|
SourceFiles/boxes/usernamebox.cpp
|
|
|
|
|
SourceFiles/chat_helpers/bot_keyboard.cpp
|
|
|
|
|
SourceFiles/chat_helpers/emoji_list_widget.cpp
|
|
|
|
|
SourceFiles/chat_helpers/field_autocomplete.cpp
|
|
|
|
|
SourceFiles/chat_helpers/gifs_list_widget.cpp
|
|
|
|
|
SourceFiles/chat_helpers/message_field.cpp
|
|
|
|
|
SourceFiles/chat_helpers/stickers.cpp
|
|
|
|
|
SourceFiles/chat_helpers/stickers_list_widget.cpp
|
|
|
|
|
SourceFiles/chat_helpers/tabbed_panel.cpp
|
|
|
|
|
SourceFiles/chat_helpers/tabbed_section.cpp
|
|
|
|
|
SourceFiles/chat_helpers/tabbed_selector.cpp
|
|
|
|
|
|
|
|
|
|
SourceFiles/core/click_handler.cpp
|
|
|
|
|
SourceFiles/core/click_handler_types.cpp
|
|
|
|
|
SourceFiles/core/observer.cpp
|
|
|
|
|
SourceFiles/core/parse_helper.cpp
|
|
|
|
|
SourceFiles/core/qthelp_url.cpp
|
|
|
|
|
SourceFiles/core/runtime_composer.cpp
|
|
|
|
|
SourceFiles/core/file_utilities.cpp
|
|
|
|
|
SourceFiles/core/single_timer.cpp
|
|
|
|
|
SourceFiles/core/task_queue.cpp
|
|
|
|
|
SourceFiles/core/utils.cpp
|
|
|
|
|
|
|
|
|
|
SourceFiles/data/data_abstract_structure.cpp
|
|
|
|
@ -227,9 +175,9 @@ set(APP_SRC
|
|
|
|
|
SourceFiles/dialogs/dialogs_list.cpp
|
|
|
|
|
SourceFiles/dialogs/dialogs_row.cpp
|
|
|
|
|
|
|
|
|
|
SourceFiles/history/field_autocomplete.cpp
|
|
|
|
|
SourceFiles/history/history_drag_area.cpp
|
|
|
|
|
SourceFiles/history/history_item.cpp
|
|
|
|
|
SourceFiles/history/history_inner_widget.cpp
|
|
|
|
|
SourceFiles/history/history_location_manager.cpp
|
|
|
|
|
SourceFiles/history/history_media_types.cpp
|
|
|
|
|
SourceFiles/history/history_message.cpp
|
|
|
|
@ -239,6 +187,7 @@ set(APP_SRC
|
|
|
|
|
SourceFiles/inline_bots/inline_bot_layout_item.cpp
|
|
|
|
|
SourceFiles/inline_bots/inline_bot_result.cpp
|
|
|
|
|
SourceFiles/inline_bots/inline_bot_send_data.cpp
|
|
|
|
|
SourceFiles/inline_bots/inline_results_widget.cpp
|
|
|
|
|
|
|
|
|
|
SourceFiles/intro/introcode.cpp
|
|
|
|
|
SourceFiles/intro/introphone.cpp
|
|
|
|
@ -247,16 +196,6 @@ set(APP_SRC
|
|
|
|
|
SourceFiles/intro/introstart.cpp
|
|
|
|
|
SourceFiles/intro/introwidget.cpp
|
|
|
|
|
|
|
|
|
|
SourceFiles/media/media_audio.cpp
|
|
|
|
|
SourceFiles/media/media_audio_ffmpeg_loader.cpp
|
|
|
|
|
SourceFiles/media/media_audio_loader.cpp
|
|
|
|
|
SourceFiles/media/media_audio_loaders.cpp
|
|
|
|
|
SourceFiles/media/media_child_ffmpeg_loader.cpp
|
|
|
|
|
SourceFiles/media/media_clip_ffmpeg.cpp
|
|
|
|
|
SourceFiles/media/media_clip_implementation.cpp
|
|
|
|
|
SourceFiles/media/media_clip_qtgif.cpp
|
|
|
|
|
SourceFiles/media/media_clip_reader.cpp
|
|
|
|
|
|
|
|
|
|
SourceFiles/media/player/media_player_button.cpp
|
|
|
|
|
SourceFiles/media/player/media_player_cover.cpp
|
|
|
|
|
SourceFiles/media/player/media_player_instance.cpp
|
|
|
|
@ -268,6 +207,16 @@ set(APP_SRC
|
|
|
|
|
SourceFiles/media/view/media_clip_controller.cpp
|
|
|
|
|
SourceFiles/media/view/media_clip_playback.cpp
|
|
|
|
|
SourceFiles/media/view/media_clip_volume_controller.cpp
|
|
|
|
|
SourceFiles/media/media_audio.cpp
|
|
|
|
|
SourceFiles/media/media_audio_capture.cpp
|
|
|
|
|
SourceFiles/media/media_audio_ffmpeg_loader.cpp
|
|
|
|
|
SourceFiles/media/media_audio_loader.cpp
|
|
|
|
|
SourceFiles/media/media_audio_loaders.cpp
|
|
|
|
|
SourceFiles/media/media_child_ffmpeg_loader.cpp
|
|
|
|
|
SourceFiles/media/media_clip_ffmpeg.cpp
|
|
|
|
|
SourceFiles/media/media_clip_implementation.cpp
|
|
|
|
|
SourceFiles/media/media_clip_qtgif.cpp
|
|
|
|
|
SourceFiles/media/media_clip_reader.cpp
|
|
|
|
|
|
|
|
|
|
SourceFiles/mtproto/auth_key.cpp
|
|
|
|
|
SourceFiles/mtproto/connection.cpp
|
|
|
|
@ -277,11 +226,11 @@ set(APP_SRC
|
|
|
|
|
SourceFiles/mtproto/connection_tcp.cpp
|
|
|
|
|
SourceFiles/mtproto/core_types.cpp
|
|
|
|
|
SourceFiles/mtproto/dcenter.cpp
|
|
|
|
|
SourceFiles/mtproto/dc_options.cpp
|
|
|
|
|
SourceFiles/mtproto/facade.cpp
|
|
|
|
|
SourceFiles/mtproto/file_download.cpp
|
|
|
|
|
SourceFiles/mtproto/rpc_sender.cpp
|
|
|
|
|
SourceFiles/mtproto/mtp_instance.cpp
|
|
|
|
|
SourceFiles/mtproto/rsa_public_key.cpp
|
|
|
|
|
SourceFiles/mtproto/scheme_auto.cpp
|
|
|
|
|
SourceFiles/mtproto/session.cpp
|
|
|
|
|
|
|
|
|
|
SourceFiles/overview/overview_layout.cpp
|
|
|
|
@ -305,9 +254,6 @@ set(APP_SRC
|
|
|
|
|
SourceFiles/profile/profile_userpic_button.cpp
|
|
|
|
|
SourceFiles/profile/profile_widget.cpp
|
|
|
|
|
|
|
|
|
|
SourceFiles/serialize/serialize_common.cpp
|
|
|
|
|
SourceFiles/serialize/serialize_document.cpp
|
|
|
|
|
|
|
|
|
|
SourceFiles/settings/settings_advanced_widget.cpp
|
|
|
|
|
SourceFiles/settings/settings_background_widget.cpp
|
|
|
|
|
SourceFiles/settings/settings_block_widget.cpp
|
|
|
|
@ -317,24 +263,19 @@ set(APP_SRC
|
|
|
|
|
SourceFiles/settings/settings_general_widget.cpp
|
|
|
|
|
SourceFiles/settings/settings_info_widget.cpp
|
|
|
|
|
SourceFiles/settings/settings_inner_widget.cpp
|
|
|
|
|
SourceFiles/settings/settings_layer.cpp
|
|
|
|
|
SourceFiles/settings/settings_notifications_widget.cpp
|
|
|
|
|
SourceFiles/settings/settings_privacy_controllers.cpp
|
|
|
|
|
SourceFiles/settings/settings_privacy_widget.cpp
|
|
|
|
|
SourceFiles/settings/settings_scale_widget.cpp
|
|
|
|
|
SourceFiles/settings/settings_widget.cpp
|
|
|
|
|
|
|
|
|
|
SourceFiles/stickers/emoji_pan.cpp
|
|
|
|
|
SourceFiles/stickers/stickers.cpp
|
|
|
|
|
|
|
|
|
|
SourceFiles/ui/abstract_button.cpp
|
|
|
|
|
SourceFiles/ui/animation.cpp
|
|
|
|
|
SourceFiles/ui/countryinput.cpp
|
|
|
|
|
SourceFiles/ui/emoji_config.cpp
|
|
|
|
|
SourceFiles/ui/filedialog.cpp
|
|
|
|
|
SourceFiles/ui/images.cpp
|
|
|
|
|
SourceFiles/ui/twidget.cpp
|
|
|
|
|
|
|
|
|
|
SourceFiles/ui/buttons/history_down_button.cpp
|
|
|
|
|
SourceFiles/ui/buttons/peer_avatar_button.cpp
|
|
|
|
|
SourceFiles/storage/file_download.cpp
|
|
|
|
|
SourceFiles/storage/file_upload.cpp
|
|
|
|
|
SourceFiles/storage/localimageloader.cpp
|
|
|
|
|
SourceFiles/storage/localstorage.cpp
|
|
|
|
|
SourceFiles/storage/serialize_common.cpp
|
|
|
|
|
SourceFiles/storage/serialize_document.cpp
|
|
|
|
|
|
|
|
|
|
SourceFiles/ui/effects/cross_animation.cpp
|
|
|
|
|
SourceFiles/ui/effects/panel_animation.cpp
|
|
|
|
@ -374,7 +315,13 @@ set(APP_SRC
|
|
|
|
|
SourceFiles/ui/widgets/scroll_area.cpp
|
|
|
|
|
SourceFiles/ui/widgets/shadow.cpp
|
|
|
|
|
SourceFiles/ui/widgets/tooltip.cpp
|
|
|
|
|
|
|
|
|
|
SourceFiles/ui/abstract_button.cpp
|
|
|
|
|
SourceFiles/ui/animation.cpp
|
|
|
|
|
SourceFiles/ui/countryinput.cpp
|
|
|
|
|
SourceFiles/ui/emoji_config.cpp
|
|
|
|
|
SourceFiles/ui/images.cpp
|
|
|
|
|
SourceFiles/ui/special_buttons.cpp
|
|
|
|
|
SourceFiles/ui/twidget.cpp
|
|
|
|
|
SourceFiles/window/main_window.cpp
|
|
|
|
|
SourceFiles/window/notifications_manager.cpp
|
|
|
|
|
SourceFiles/window/notifications_manager_default.cpp
|
|
|
|
@ -382,31 +329,59 @@ set(APP_SRC
|
|
|
|
|
SourceFiles/window/player_wrap_widget.cpp
|
|
|
|
|
SourceFiles/window/section_widget.cpp
|
|
|
|
|
SourceFiles/window/top_bar_widget.cpp
|
|
|
|
|
SourceFiles/window/window_controller.cpp
|
|
|
|
|
SourceFiles/window/window_main_menu.cpp
|
|
|
|
|
SourceFiles/window/window_slide_animation.cpp
|
|
|
|
|
SourceFiles/window/window_theme.cpp
|
|
|
|
|
SourceFiles/window/window_theme_preview.cpp
|
|
|
|
|
SourceFiles/window/window_theme_warning.cpp
|
|
|
|
|
SourceFiles/window/themes/window_theme.cpp
|
|
|
|
|
SourceFiles/window/themes/window_theme_editor.cpp
|
|
|
|
|
SourceFiles/window/themes/window_theme_editor_block.cpp
|
|
|
|
|
SourceFiles/window/themes/window_theme_preview.cpp
|
|
|
|
|
SourceFiles/window/themes/window_theme_warning.cpp
|
|
|
|
|
SourceFiles/apiwrap.cpp
|
|
|
|
|
SourceFiles/app.cpp
|
|
|
|
|
SourceFiles/application.cpp
|
|
|
|
|
SourceFiles/auth_session.cpp
|
|
|
|
|
SourceFiles/autoupdater.cpp
|
|
|
|
|
SourceFiles/facades.cpp
|
|
|
|
|
SourceFiles/layerwidget.cpp
|
|
|
|
|
SourceFiles/layout.cpp
|
|
|
|
|
SourceFiles/logs.cpp
|
|
|
|
|
SourceFiles/main.cpp
|
|
|
|
|
SourceFiles/mainwidget.cpp
|
|
|
|
|
SourceFiles/mainwindow.cpp
|
|
|
|
|
SourceFiles/mediaview.cpp
|
|
|
|
|
SourceFiles/messenger.cpp
|
|
|
|
|
SourceFiles/observer_peer.cpp
|
|
|
|
|
SourceFiles/overviewwidget.cpp
|
|
|
|
|
SourceFiles/passcodewidget.cpp
|
|
|
|
|
SourceFiles/qt_functions.cpp
|
|
|
|
|
SourceFiles/qt_static_plugins.cpp
|
|
|
|
|
SourceFiles/settings.cpp
|
|
|
|
|
SourceFiles/shortcuts.cpp
|
|
|
|
|
SourceFiles/structs.cpp
|
|
|
|
|
)
|
|
|
|
|
|
|
|
|
|
set(PLAT_SRC)
|
|
|
|
|
|
|
|
|
|
if (APPLE)
|
|
|
|
|
set(PLAT_SRC ${PLAT_SRC}
|
|
|
|
|
SourceFiles/pspecific_mac.cpp
|
|
|
|
|
SourceFiles/pspecific_mac_p.mm
|
|
|
|
|
SourceFiles/platform/mac/file_dialog_mac.mm
|
|
|
|
|
SourceFiles/platform/mac/file_utilities_mac.mm
|
|
|
|
|
SourceFiles/platform/mac/mac_iconv_helper.c
|
|
|
|
|
SourceFiles/platform/mac/mac_utilities.mm
|
|
|
|
|
SourceFiles/platform/mac/main_window_mac.mm
|
|
|
|
|
SourceFiles/platform/mac/notifications_manager_mac.mm
|
|
|
|
|
SourceFiles/platform/mac/specific_mac.mm
|
|
|
|
|
SourceFiles/platform/mac/specific_mac_p.mm
|
|
|
|
|
SourceFiles/platform/mac/window_title_mac.mm
|
|
|
|
|
)
|
|
|
|
|
endif()
|
|
|
|
|
if (WIN32)
|
|
|
|
|
set(PLAT_SRC ${PLAT_SRC}
|
|
|
|
|
SourceFiles/pspecific_win.cpp
|
|
|
|
|
SourceFiles/platform/win/audio_win.cpp
|
|
|
|
|
SourceFiles/platform/win/file_utilities_win.cpp
|
|
|
|
|
SourceFiles/platform/win/main_window_win.cpp
|
|
|
|
|
SourceFiles/platform/win/notifications_manager_win.cpp
|
|
|
|
|
SourceFiles/platform/win/specific_win.cpp
|
|
|
|
|
SourceFiles/platform/win/window_title_win.cpp
|
|
|
|
|
SourceFiles/platform/win/windows_app_user_model_id.cpp
|
|
|
|
|
SourceFiles/platform/win/windows_dlls.cpp
|
|
|
|
@ -415,19 +390,19 @@ if (WIN32)
|
|
|
|
|
endif()
|
|
|
|
|
if (WINRT)
|
|
|
|
|
set(PLAT_SRC ${PLAT_SRC}
|
|
|
|
|
SourceFiles/pspecific_winrt.cpp
|
|
|
|
|
SourceFiles/platform/winrt/main_window_winrt.cpp
|
|
|
|
|
)
|
|
|
|
|
endif()
|
|
|
|
|
if (LINUX)
|
|
|
|
|
set(PLAT_SRC ${PLAT_SRC}
|
|
|
|
|
SourceFiles/pspecific_linux.cpp
|
|
|
|
|
SourceFiles/platform/linux/file_dialog_linux.cpp
|
|
|
|
|
SourceFiles/platform/linux/file_utilities_linux.cpp
|
|
|
|
|
SourceFiles/platform/linux/linux_desktop_environment.cpp
|
|
|
|
|
SourceFiles/platform/linux/linux_gdk_helper.cpp
|
|
|
|
|
SourceFiles/platform/linux/linux_libnotify.cpp
|
|
|
|
|
SourceFiles/platform/linux/linux_libs.cpp
|
|
|
|
|
SourceFiles/platform/linux/main_window_linux.cpp
|
|
|
|
|
SourceFiles/platform/linux/notifications_manager_linux.cpp
|
|
|
|
|
SourceFiles/platform/linux/specific_linux.cpp
|
|
|
|
|
)
|
|
|
|
|
endif()
|
|
|
|
|
|
|
|
|
@ -456,7 +431,7 @@ include_directories(SourceFiles SourceFiles/core)
|
|
|
|
|
|
|
|
|
|
include_directories(${OPENAL_INCLUDE_DIR} ${ZLIB_INCLUDE_DIRS}
|
|
|
|
|
${LIBZIP_INCLUDE_DIR_ZIP} ${LIBZIP_INCLUDE_DIR_ZIPCONF}
|
|
|
|
|
${OPENSSL_INCLUDE_DIR} ${LIBLZMA_INCLUDE_DIRS} ${GTK3_INCLUDE_DIRS} )
|
|
|
|
|
${OPENSSL_INCLUDE_DIR} ${LIBLZMA_INCLUDE_DIRS} ${GTK3_INCLUDE_DIRS})
|
|
|
|
|
|
|
|
|
|
link_directories(${GTK3_LIBRARY_DIRS})
|
|
|
|
|
|
|
|
|
@ -464,13 +439,21 @@ link_directories(${GTK3_LIBRARY_DIRS})
|
|
|
|
|
include_directories(/usr/local/opt/openal-soft/include)
|
|
|
|
|
add_definitions(-Wno-switch)
|
|
|
|
|
# End remove me
|
|
|
|
|
if (WIN32)
|
|
|
|
|
add_definitions(-DTDESKTOP_DISABLE_CRASH_REPORTS -D_CRT_SECURE_NO_WARNINGS -DWIN32 -D_WINDOWS -DUNICODE -DWIN64 -DWINAPI_FAMILY=WINAPI_FAMILY_DESKTOP_APP)
|
|
|
|
|
endif()
|
|
|
|
|
|
|
|
|
|
add_executable(Telegram ${APP_SRC} ${PLAT_SRC} ${THIRD_PARTY_SRC})
|
|
|
|
|
target_link_libraries(Telegram tg_boxes)
|
|
|
|
|
target_link_libraries(Telegram Qt5::Core Qt5::Widgets) # crashpad::crashpad_client)
|
|
|
|
|
target_link_libraries(Telegram ${LIBLZMA_LIBRARIES} ${OPENSSL_LIBRARIES} ${ZLIB_LIBRARIES} ${OPENAL_LIBRARY})
|
|
|
|
|
qt5_use_modules(Telegram Core Widgets)
|
|
|
|
|
|
|
|
|
|
set_target_properties(Telegram PROPERTIES COTIRE_CXX_PREFIX_HEADER_INIT "SourceFiles/stdafx.h")
|
|
|
|
|
set_target_properties(Telegram
|
|
|
|
|
PROPERTIES
|
|
|
|
|
COTIRE_CXX_PREFIX_HEADER_INIT SourceFiles/stdafx.h
|
|
|
|
|
COTIRE_ADD_UNITY_BUILD FALSE
|
|
|
|
|
)
|
|
|
|
|
cotire(Telegram)
|
|
|
|
|
|
|
|
|
|
##======================
|
|
|
|
|