Compare commits
310 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
1a16df4037 | ||
|
|
0edca8cfdb | ||
|
|
019939a09d | ||
|
|
9d66e88fc1 | ||
|
|
d0a7e6be73 | ||
|
|
72e34dc5b1 | ||
|
|
a86c85485a | ||
|
|
3da020dffd | ||
|
|
c65a280b9d | ||
|
|
eec5b78054 | ||
|
|
218f991547 | ||
|
|
bc0c355d2d | ||
|
|
b39987c343 | ||
|
|
1d8e76aa08 | ||
|
|
204d91d567 | ||
|
|
38e6a0ae7e | ||
|
|
ef927c8465 | ||
|
|
1d895cd953 | ||
|
|
eb4d2a38b6 | ||
|
|
b030824ef5 | ||
|
|
177078b0af | ||
|
|
0480e02b23 | ||
|
|
2436ad74bd | ||
|
|
85b434bee4 | ||
|
|
90234cb7a0 | ||
|
|
2d48cde27a | ||
|
|
4692fdeb5f | ||
|
|
47977009b8 | ||
|
|
06ed7b8eaf | ||
|
|
a248cef15d | ||
|
|
74253fb7f2 | ||
|
|
7bb3b4d807 | ||
|
|
a3c406dd00 | ||
|
|
3e6d483939 | ||
|
|
b0f14d1856 | ||
|
|
2796c53542 | ||
|
|
8958ae0377 | ||
|
|
2b3631f3ae | ||
|
|
3cff50009c | ||
|
|
26c08236cd | ||
|
|
3da0533339 | ||
|
|
6e0394dd42 | ||
|
|
38d20c506e | ||
|
|
b1ca0f5ea3 | ||
|
|
eb05e62422 | ||
|
|
9155591e8a | ||
|
|
9fa284a6d1 | ||
|
|
e880c4876e | ||
|
|
8a0c275658 | ||
|
|
2ada4d841f | ||
|
|
d313bd56a6 | ||
|
|
d607f0768a | ||
|
|
31a66d66e2 | ||
|
|
d0f7c6c210 | ||
|
|
07689476a6 | ||
|
|
cdef9fa14f | ||
|
|
7fa274a68e | ||
|
|
3186e1e495 | ||
|
|
48eb72a9c2 | ||
|
|
78f55c10e9 | ||
|
|
a74baaea36 | ||
|
|
807bebb3cf | ||
|
|
d4d1d438be | ||
|
|
55b1ba128d | ||
|
|
bd2be4e0c1 | ||
|
|
27ff8d4bf5 | ||
|
|
1310b156dc | ||
|
|
3366e05b77 | ||
|
|
45ce0ecb1f | ||
|
|
8ff3779c9a | ||
|
|
494254496e | ||
|
|
475b35bf55 | ||
|
|
19f4e50e33 | ||
|
|
fac8e48381 | ||
|
|
dd9bd43331 | ||
|
|
23c2e5364a | ||
|
|
0326976473 | ||
|
|
dac96bfc4a | ||
|
|
b3d1602354 | ||
|
|
d12177befd | ||
|
|
e693a98bd4 | ||
|
|
3a599e0752 | ||
|
|
0cbb0014db | ||
|
|
1ecd6866c7 | ||
|
|
1466338e7e | ||
|
|
2a3fd0066d | ||
|
|
5d10c02b5b | ||
|
|
af9edc17d2 | ||
|
|
c932f3d9df | ||
|
|
e08f5437a6 | ||
|
|
dbb6371e67 | ||
|
|
b2414939c9 | ||
|
|
19b77ee4ac | ||
|
|
09b429592f | ||
|
|
7f71ef3784 | ||
|
|
2dadf7ce57 | ||
|
|
d460897f84 | ||
|
|
9dc660c8ec | ||
|
|
1f0e2b1692 | ||
|
|
8d6e1b1697 | ||
|
|
2e4426aac0 | ||
|
|
42e544abff | ||
|
|
f7374aa7b7 | ||
|
|
9f2b6a7ee1 | ||
|
|
29493a0693 | ||
|
|
6e33f039b2 | ||
|
|
140e6d6268 | ||
|
|
ec6e46dae7 | ||
|
|
abd755d7fc | ||
|
|
ff2d959abd | ||
|
|
d35b295d5e | ||
|
|
a65c76ea69 | ||
|
|
802349d042 | ||
|
|
c8a379e85e | ||
|
|
1cfe9d0ff5 | ||
|
|
53e48beb03 | ||
|
|
d2e27726ca | ||
|
|
a774e9b712 | ||
|
|
6d9173bca8 | ||
|
|
c1d862d8de | ||
|
|
e1478359e6 | ||
|
|
8bc4e3816b | ||
|
|
48332c0c6b | ||
|
|
3455344c62 | ||
|
|
e5a5273b3a | ||
|
|
2bd561821a | ||
|
|
763b347a8f | ||
|
|
c514c62d61 | ||
|
|
130c41d711 | ||
|
|
77df38b4fd | ||
|
|
c773bffec6 | ||
|
|
20d04a065e | ||
|
|
951d93832c | ||
|
|
143cfe0d0f | ||
|
|
3b843f3d0f | ||
|
|
5ad2fc12d9 | ||
|
|
9752224449 | ||
|
|
f1307f70ce | ||
|
|
2ffc0196dd | ||
|
|
3503be03c9 | ||
|
|
40fc7379bc | ||
|
|
48a20f0e71 | ||
|
|
b33b59b8b9 | ||
|
|
2f4b2d0a33 | ||
|
|
ba4dcc42dc | ||
|
|
fc7c5d0ab3 | ||
|
|
086f754a96 | ||
|
|
7345408568 | ||
|
|
e536d5ad59 | ||
|
|
72b26861a9 | ||
|
|
eb6b2c7d2e | ||
|
|
48fde28484 | ||
|
|
fd6a312abc | ||
|
|
eb939fa4b0 | ||
|
|
0902741b85 | ||
|
|
cf247384d3 | ||
|
|
fa0e255183 | ||
|
|
5d6dafeeda | ||
|
|
31a847fb9d | ||
|
|
4f0cff5467 | ||
|
|
d543073632 | ||
|
|
956d048d56 | ||
|
|
9eb8a93719 | ||
|
|
d919f3e705 | ||
|
|
9950629e4e | ||
|
|
8f135d7e00 | ||
|
|
8d13014613 | ||
|
|
1a67b31ee9 | ||
|
|
2d9ccbc428 | ||
|
|
3c8fb5f1f6 | ||
|
|
e616c39608 | ||
|
|
377d333f1c | ||
|
|
6798b86655 | ||
|
|
b298c72b52 | ||
|
|
f1d52c12ae | ||
|
|
4a9821117b | ||
|
|
3c84899edf | ||
|
|
4369c23314 | ||
|
|
15ee4b40dc | ||
|
|
eb47b9468c | ||
|
|
16ce28f4d2 | ||
|
|
e7b6d7b498 | ||
|
|
41dc0f4e98 | ||
|
|
043cba0a64 | ||
|
|
c8aa7672e9 | ||
|
|
a9929a5d51 | ||
|
|
79a90956f7 | ||
|
|
9fdd75113f | ||
|
|
b600050057 | ||
|
|
c9288f2d0a | ||
|
|
f710fe2dd3 | ||
|
|
aa17702c01 | ||
|
|
9d6fb22d11 | ||
|
|
4875060e8f | ||
|
|
6db52f7fa9 | ||
|
|
1cc1aab823 | ||
|
|
1a645a8496 | ||
|
|
e1a8c89ff1 | ||
|
|
2d1d62a953 | ||
|
|
7f950d2de2 | ||
|
|
c2aa8d3c77 | ||
|
|
0bf55835f5 | ||
|
|
a41e0c4aa7 | ||
|
|
1d6aba86ba | ||
|
|
45dabbf9ab | ||
|
|
4bdb2c48c7 | ||
|
|
4a5f467560 | ||
|
|
ef2faf676e | ||
|
|
3d2f025e10 | ||
|
|
acbaf83442 | ||
|
|
1b54ccb59c | ||
|
|
886327a1d0 | ||
|
|
2ebab6a13c | ||
|
|
a18e3e5616 | ||
|
|
376941dd5e | ||
|
|
828b42e4f1 | ||
|
|
a5eee9bd3e | ||
|
|
fee1cec3d9 | ||
|
|
1247bd19b6 | ||
|
|
325e28f3a8 | ||
|
|
5d37517eac | ||
|
|
5b3ac58578 | ||
|
|
01a5aa30df | ||
|
|
6b8d3aa48c | ||
|
|
f1f7333c7a | ||
|
|
73a8d27bfd | ||
|
|
139882113d | ||
|
|
5b7d936140 | ||
|
|
903795d0e5 | ||
|
|
0562024444 | ||
|
|
78815800d0 | ||
|
|
344890c533 | ||
|
|
5529e24000 | ||
|
|
538ffb9727 | ||
|
|
d277b0d4bb | ||
|
|
90a4b66366 | ||
|
|
da49d8440a | ||
|
|
18f3e45657 | ||
|
|
c91bdf3fef | ||
|
|
8546814a25 | ||
|
|
453661d611 | ||
|
|
866bc4ff8a | ||
|
|
ff3e6c429d | ||
|
|
52731a737a | ||
|
|
3d8dadc2e7 | ||
|
|
042c9fc23d | ||
|
|
38114d3297 | ||
|
|
947963d5d1 | ||
|
|
efbf67a8ff | ||
|
|
3e4088b413 | ||
|
|
0479b214da | ||
|
|
3d9e0030c5 | ||
|
|
780fe61ff2 | ||
|
|
f970ac3163 | ||
|
|
a8f3582cb1 | ||
|
|
47eead17b1 | ||
|
|
5c20ae0411 | ||
|
|
c563280b76 | ||
|
|
c4a4e99f6b | ||
|
|
75c12dda31 | ||
|
|
2ea4c87d78 | ||
|
|
1da2a7c10c | ||
|
|
f7999bc993 | ||
|
|
227aa36627 | ||
|
|
ce1973fd30 | ||
|
|
50fa8b63c9 | ||
|
|
37b5329af3 | ||
|
|
6d2fc5c642 | ||
|
|
578cf4ed61 | ||
|
|
298bd2a476 | ||
|
|
c00456e12e | ||
|
|
708bf688ea | ||
|
|
96202f775c | ||
|
|
26ca5fafbb | ||
|
|
3423bd69dc | ||
|
|
a7b692e8ed | ||
|
|
e623d05e37 | ||
|
|
cb798ab3c5 | ||
|
|
f83610778a | ||
|
|
8660ab555b | ||
|
|
ffe75444d1 | ||
|
|
86982da5f7 | ||
|
|
a62a47098e | ||
|
|
1629793ace | ||
|
|
273637f9ac | ||
|
|
e90468f67b | ||
|
|
a41912cdf3 | ||
|
|
07e2eb4c57 | ||
|
|
f517494c91 | ||
|
|
c7e8b153bb | ||
|
|
8419a56e10 | ||
|
|
ff657347b8 | ||
|
|
b5640fdb0a | ||
|
|
58933df54b | ||
|
|
96a0e1c237 | ||
|
|
82d92d21f6 | ||
|
|
34331f558f | ||
|
|
52a7ed77ba | ||
|
|
589b7310c1 | ||
|
|
326d22565d | ||
|
|
2f206bf6bc | ||
|
|
d8444cb5d0 | ||
|
|
ab18fc6478 | ||
|
|
610d42fd8d | ||
|
|
3d3fc33253 | ||
|
|
b772e42ca1 | ||
|
|
160895f6e3 | ||
|
|
43a40c3b9a | ||
|
|
71cfc83c1d | ||
|
|
10f3d2049a |
5
.gitattributes
vendored
Normal file
@@ -0,0 +1,5 @@
|
||||
# Set the default behavior, in case people don't have core.autocrlf set.
|
||||
* text=auto
|
||||
|
||||
# Ensure diffs have LF endings
|
||||
*.diff text eol=lf
|
||||
@@ -50,6 +50,7 @@ addons:
|
||||
- libssl-dev
|
||||
- libunity-dev
|
||||
- libva-dev
|
||||
- libvdpau-dev
|
||||
- libxcb-xkb-dev
|
||||
- libxkbcommon-dev
|
||||
- lintian
|
||||
|
||||
798
.travis/build.sh
@@ -9,316 +9,622 @@ UPSTREAM="$REPO/upstream"
|
||||
EXTERNAL="$REPO/external"
|
||||
CACHE="$HOME/travisCacheDir"
|
||||
|
||||
QT_PATH="$BUILD/qt"
|
||||
BREAKPAD_PATH="$EXTERNAL/breakpad"
|
||||
QT_VERSION=5.6.2
|
||||
|
||||
[[ ! $MAKE_ARGS ]] && MAKE_ARGS="--quiet -j4"
|
||||
QT_VERSION=5.6.0
|
||||
XKB_PATH="$BUILD/libxkbcommon"
|
||||
XKB_CACHE_VERSION="2"
|
||||
|
||||
QT_PATH="$BUILD/qt"
|
||||
QT_CACHE_VERSION="2"
|
||||
QT_PATCH="$UPSTREAM/Telegram/Patches/qtbase_${QT_VERSION//\./_}.diff"
|
||||
|
||||
BREAKPAD_PATH="$BUILD/breakpad"
|
||||
BREAKPAD_CACHE_VERSION="2"
|
||||
|
||||
GYP_PATH="$BUILD/gyp"
|
||||
GYP_CACHE_VERSION="2"
|
||||
GYP_PATCH="$UPSTREAM/Telegram/Patches/gyp.diff"
|
||||
|
||||
VA_PATH="$BUILD/libva"
|
||||
VA_CACHE_VERSION="2"
|
||||
|
||||
VDPAU_PATH="$BUILD/libvdpau"
|
||||
VDPAU_CACHE_VERSION="1"
|
||||
|
||||
FFMPEG_PATH="$BUILD/ffmpeg"
|
||||
FFMPEG_CACHE_VERSION="2"
|
||||
|
||||
OPENAL_PATH="$BUILD/openal-soft"
|
||||
OPENAL_CACHE_VERSION="2"
|
||||
|
||||
GYP_DEFINES=""
|
||||
|
||||
[[ ! $MAKE_ARGS ]] && MAKE_ARGS="--silent -j4"
|
||||
|
||||
run() {
|
||||
# Move files to subdir
|
||||
cd ..
|
||||
mv tdesktop tdesktop2
|
||||
mkdir tdesktop
|
||||
mv tdesktop2 "$UPSTREAM"
|
||||
# Move files to subdir
|
||||
cd ..
|
||||
mv tdesktop tdesktop2
|
||||
mkdir tdesktop
|
||||
mv tdesktop2 "$UPSTREAM"
|
||||
|
||||
mkdir "$BUILD"
|
||||
mkdir "$BUILD"
|
||||
|
||||
downloadLibs
|
||||
build
|
||||
check
|
||||
}
|
||||
|
||||
# install
|
||||
downloadLibs() {
|
||||
travisStartFold "Download libraries"
|
||||
|
||||
cd "$REPO"
|
||||
mkdir external && cd external
|
||||
|
||||
git clone https://chromium.googlesource.com/linux-syscall-support
|
||||
git clone https://git.ffmpeg.org/ffmpeg.git
|
||||
git clone https://github.com/xkbcommon/libxkbcommon.git
|
||||
git clone https://github.com/kcat/openal-soft.git
|
||||
build
|
||||
check
|
||||
}
|
||||
|
||||
build() {
|
||||
travisStartFold "Build libraries"
|
||||
mkdir -p "$EXTERNAL"
|
||||
|
||||
# libxkbcommon
|
||||
cd "$EXTERNAL/libxkbcommon"
|
||||
./autogen.sh \
|
||||
--prefix='/usr/local'
|
||||
make $MAKE_ARGS
|
||||
sudo make install
|
||||
sudo ldconfig
|
||||
# libxkbcommon
|
||||
getXkbCommon
|
||||
|
||||
# ffmpeg
|
||||
cd "$EXTERNAL/ffmpeg"
|
||||
./configure \
|
||||
--prefix='/usr/local' \
|
||||
--disable-debug \
|
||||
--disable-programs \
|
||||
--disable-doc \
|
||||
--disable-everything \
|
||||
--enable-gpl \
|
||||
--enable-version3 \
|
||||
--enable-libopus \
|
||||
--enable-decoder=aac \
|
||||
--enable-decoder=aac_latm \
|
||||
--enable-decoder=aasc \
|
||||
--enable-decoder=flac \
|
||||
--enable-decoder=gif \
|
||||
--enable-decoder=h264 \
|
||||
--enable-decoder=h264_vdpau \
|
||||
--enable-decoder=mp1 \
|
||||
--enable-decoder=mp1float \
|
||||
--enable-decoder=mp2 \
|
||||
--enable-decoder=mp2float \
|
||||
--enable-decoder=mp3 \
|
||||
--enable-decoder=mp3adu \
|
||||
--enable-decoder=mp3adufloat \
|
||||
--enable-decoder=mp3float \
|
||||
--enable-decoder=mp3on4 \
|
||||
--enable-decoder=mp3on4float \
|
||||
--enable-decoder=mpeg4 \
|
||||
--enable-decoder=mpeg4_vdpau \
|
||||
--enable-decoder=msmpeg4v2 \
|
||||
--enable-decoder=msmpeg4v3 \
|
||||
--enable-decoder=opus \
|
||||
--enable-decoder=vorbis \
|
||||
--enable-decoder=wavpack \
|
||||
--enable-decoder=wmalossless \
|
||||
--enable-decoder=wmapro \
|
||||
--enable-decoder=wmav1 \
|
||||
--enable-decoder=wmav2 \
|
||||
--enable-decoder=wmavoice \
|
||||
--enable-encoder=libopus \
|
||||
--enable-hwaccel=h264_vaapi \
|
||||
--enable-hwaccel=h264_vdpau \
|
||||
--enable-hwaccel=mpeg4_vaapi \
|
||||
--enable-hwaccel=mpeg4_vdpau \
|
||||
--enable-parser=aac \
|
||||
--enable-parser=aac_latm \
|
||||
--enable-parser=flac \
|
||||
--enable-parser=h264 \
|
||||
--enable-parser=mpeg4video \
|
||||
--enable-parser=mpegaudio \
|
||||
--enable-parser=opus \
|
||||
--enable-parser=vorbis \
|
||||
--enable-demuxer=aac \
|
||||
--enable-demuxer=flac \
|
||||
--enable-demuxer=gif \
|
||||
--enable-demuxer=h264 \
|
||||
--enable-demuxer=mov \
|
||||
--enable-demuxer=mp3 \
|
||||
--enable-demuxer=ogg \
|
||||
--enable-demuxer=wav \
|
||||
--enable-muxer=ogg \
|
||||
--enable-muxer=opus
|
||||
make $MAKE_ARGS
|
||||
sudo make install
|
||||
sudo ldconfig
|
||||
# libva
|
||||
getVa
|
||||
|
||||
# openal_soft
|
||||
cd "$EXTERNAL/openal-soft/build"
|
||||
cmake \
|
||||
-D CMAKE_INSTALL_PREFIX=/usr/local \
|
||||
-D CMAKE_BUILD_TYPE=Release \
|
||||
-D LIBTYPE=STATIC \
|
||||
..
|
||||
make $MAKE_ARGS
|
||||
sudo make install
|
||||
sudo ldconfig
|
||||
# libvdpau
|
||||
getVdpau
|
||||
|
||||
# Qt
|
||||
getCustomQt
|
||||
# ffmpeg
|
||||
getFFmpeg
|
||||
|
||||
# Breakpad
|
||||
getBreakpad
|
||||
# openal_soft
|
||||
getOpenAL
|
||||
|
||||
travisStartFold "Patch tdesktop"
|
||||
# Patched Qt
|
||||
getCustomQt
|
||||
|
||||
# Patch tdesktop
|
||||
sed -i 's/CUSTOM_API_ID//g' "$UPSTREAM/Telegram/Telegram.pro"
|
||||
sed -i 's,LIBS += /usr/local/lib/libxkbcommon.a,,g' "$UPSTREAM/Telegram/Telegram.pro"
|
||||
sed -i 's,#xkbcommon,xkbcommon,g' "$UPSTREAM/Telegram/Telegram.pro"
|
||||
sed -i "s,\..*/Libraries/breakpad/,$BREAKPAD_PATH/,g" "$UPSTREAM/Telegram/Telegram.pro"
|
||||
# Breakpad
|
||||
getBreakpad
|
||||
|
||||
local options=""
|
||||
# Patched GYP (supports cmake precompiled headers)
|
||||
getGYP
|
||||
|
||||
if [[ $BUILD_VERSION == *"disable_autoupdate"* ]]; then
|
||||
options+="\nDEFINES += TDESKTOP_DISABLE_AUTOUPDATE"
|
||||
fi
|
||||
# Configure the build
|
||||
if [[ $BUILD_VERSION == *"disable_autoupdate"* ]]; then
|
||||
GYP_DEFINES+=",TDESKTOP_DISABLE_AUTOUPDATE"
|
||||
fi
|
||||
|
||||
if [[ $BUILD_VERSION == *"disable_register_custom_scheme"* ]]; then
|
||||
options+="\nDEFINES += TDESKTOP_DISABLE_REGISTER_CUSTOM_SCHEME"
|
||||
fi
|
||||
if [[ $BUILD_VERSION == *"disable_register_custom_scheme"* ]]; then
|
||||
GYP_DEFINES+=",TDESKTOP_DISABLE_REGISTER_CUSTOM_SCHEME"
|
||||
fi
|
||||
|
||||
if [[ $BUILD_VERSION == *"disable_crash_reports"* ]]; then
|
||||
options+="\nDEFINES += TDESKTOP_DISABLE_CRASH_REPORTS"
|
||||
fi
|
||||
if [[ $BUILD_VERSION == *"disable_crash_reports"* ]]; then
|
||||
GYP_DEFINES+=",TDESKTOP_DISABLE_CRASH_REPORTS"
|
||||
fi
|
||||
|
||||
if [[ $BUILD_VERSION == *"disable_network_proxy"* ]]; then
|
||||
options+="\nDEFINES += TDESKTOP_DISABLE_NETWORK_PROXY"
|
||||
fi
|
||||
if [[ $BUILD_VERSION == *"disable_network_proxy"* ]]; then
|
||||
GYP_DEFINES+=",TDESKTOP_DISABLE_NETWORK_PROXY"
|
||||
fi
|
||||
|
||||
if [[ $BUILD_VERSION == *"disable_desktop_file_generation"* ]]; then
|
||||
options+="\nDEFINES += TDESKTOP_DISABLE_DESKTOP_FILE_GENERATION"
|
||||
fi
|
||||
if [[ $BUILD_VERSION == *"disable_desktop_file_generation"* ]]; then
|
||||
GYP_DEFINES+=",TDESKTOP_DISABLE_DESKTOP_FILE_GENERATION"
|
||||
fi
|
||||
|
||||
if [[ $BUILD_VERSION == *"disable_unity_integration"* ]]; then
|
||||
options+="\nDEFINES += TDESKTOP_DISABLE_UNITY_INTEGRATION"
|
||||
fi
|
||||
if [[ $BUILD_VERSION == *"disable_unity_integration"* ]]; then
|
||||
GYP_DEFINES+=",TDESKTOP_DISABLE_UNITY_INTEGRATION"
|
||||
fi
|
||||
|
||||
info_msg "Build options: ${options}"
|
||||
info_msg "Build defines: ${GYP_DEFINES}"
|
||||
|
||||
echo -e "${options}" >> "$UPSTREAM/Telegram/Telegram.pro"
|
||||
buildTelegram
|
||||
|
||||
travisStartFold "Build tdesktop"
|
||||
travisEndFold
|
||||
}
|
||||
|
||||
buildTelegram
|
||||
|
||||
travisEndFold
|
||||
getXkbCommon() {
|
||||
travisStartFold "Getting xkbcommon"
|
||||
|
||||
local XKB_CACHE="$CACHE/libxkbcommon"
|
||||
local XKB_CACHE_FILE="$XKB_CACHE/.cache.txt"
|
||||
local XKB_CACHE_KEY="${XKB_CACHE_VERSION}"
|
||||
local XKB_CACHE_OUTDATED="1"
|
||||
|
||||
if [ ! -d "$XKB_CACHE" ]; then
|
||||
mkdir -p "$XKB_CACHE"
|
||||
fi
|
||||
|
||||
ln -sf "$XKB_CACHE" "$XKB_PATH"
|
||||
|
||||
if [ -f "$XKB_CACHE_FILE" ]; then
|
||||
local XKB_CACHE_KEY_FOUND=`tail -n 1 $XKB_CACHE_FILE`
|
||||
if [ "$XKB_CACHE_KEY" == "$XKB_CACHE_KEY_FOUND" ]; then
|
||||
XKB_CACHE_OUTDATED="0"
|
||||
else
|
||||
info_msg "Cache key '$XKB_CACHE_KEY_FOUND' does not match '$XKB_CACHE_KEY', rebuilding libxkbcommon"
|
||||
fi
|
||||
fi
|
||||
if [ "$XKB_CACHE_OUTDATED" == "1" ]; then
|
||||
buildXkbCommon
|
||||
sudo echo $XKB_CACHE_KEY > "$XKB_CACHE_FILE"
|
||||
else
|
||||
info_msg "Using cached libxkbcommon"
|
||||
fi
|
||||
}
|
||||
|
||||
buildXkbCommon() {
|
||||
info_msg "Downloading and building libxkbcommon"
|
||||
|
||||
if [ -d "$EXTERNAL/libxkbcommon" ]; then
|
||||
rm -rf "$EXTERNAL/libxkbcommon"
|
||||
fi
|
||||
cd $XKB_PATH
|
||||
rm -rf *
|
||||
|
||||
cd "$EXTERNAL"
|
||||
git clone https://github.com/xkbcommon/libxkbcommon.git
|
||||
|
||||
cd "$EXTERNAL/libxkbcommon"
|
||||
./autogen.sh --prefix=$XKB_PATH
|
||||
make $MAKE_ARGS
|
||||
sudo make install
|
||||
sudo ldconfig
|
||||
}
|
||||
|
||||
getVa() {
|
||||
travisStartFold "Getting libva"
|
||||
|
||||
local VA_CACHE="$CACHE/libva"
|
||||
local VA_CACHE_FILE="$VA_CACHE/.cache.txt"
|
||||
local VA_CACHE_KEY="${VA_CACHE_VERSION}"
|
||||
local VA_CACHE_OUTDATED="1"
|
||||
|
||||
if [ ! -d "$VA_CACHE" ]; then
|
||||
mkdir -p "$VA_CACHE"
|
||||
fi
|
||||
|
||||
ln -sf "$VA_CACHE" "$VA_PATH"
|
||||
|
||||
if [ -f "$VA_CACHE_FILE" ]; then
|
||||
local VA_CACHE_KEY_FOUND=`tail -n 1 $VA_CACHE_FILE`
|
||||
if [ "$VA_CACHE_KEY" == "$VA_CACHE_KEY_FOUND" ]; then
|
||||
VA_CACHE_OUTDATED="0"
|
||||
else
|
||||
info_msg "Cache key '$VA_CACHE_KEY_FOUND' does not match '$VA_CACHE_KEY', rebuilding libva"
|
||||
fi
|
||||
fi
|
||||
if [ "$VA_CACHE_OUTDATED" == "1" ]; then
|
||||
buildVa
|
||||
sudo echo $VA_CACHE_KEY > "$VA_CACHE_FILE"
|
||||
else
|
||||
info_msg "Using cached libva"
|
||||
fi
|
||||
}
|
||||
|
||||
buildVa() {
|
||||
info_msg "Downloading and building libva"
|
||||
|
||||
if [ -d "$EXTERNAL/libva" ]; then
|
||||
rm -rf "$EXTERNAL/libva"
|
||||
fi
|
||||
cd $VA_PATH
|
||||
rm -rf *
|
||||
|
||||
cd "$EXTERNAL"
|
||||
git clone git://anongit.freedesktop.org/git/libva
|
||||
|
||||
cd "$EXTERNAL/libva"
|
||||
./autogen.sh --prefix=$VA_PATH --enable-static
|
||||
make $MAKE_ARGS
|
||||
sudo make install
|
||||
sudo ldconfig
|
||||
}
|
||||
|
||||
getVdpau() {
|
||||
travisStartFold "Getting libvdpau"
|
||||
|
||||
local VDPAU_CACHE="$CACHE/libvdpau"
|
||||
local VDPAU_CACHE_FILE="$VDPAU_CACHE/.cache.txt"
|
||||
local VDPAU_CACHE_KEY="${VDPAU_CACHE_VERSION}"
|
||||
local VDPAU_CACHE_OUTDATED="1"
|
||||
|
||||
if [ ! -d "$VDPAU_CACHE" ]; then
|
||||
mkdir -p "$VDPAU_CACHE"
|
||||
fi
|
||||
|
||||
ln -sf "$VDPAU_CACHE" "$VDPAU_PATH"
|
||||
|
||||
if [ -f "$VDPAU_CACHE_FILE" ]; then
|
||||
local VDPAU_CACHE_KEY_FOUND=`tail -n 1 $VDPAU_CACHE_FILE`
|
||||
if [ "$VDPAU_CACHE_KEY" == "$VDPAU_CACHE_KEY_FOUND" ]; then
|
||||
VDPAU_CACHE_OUTDATED="0"
|
||||
else
|
||||
info_msg "Cache key '$VDPAU_CACHE_KEY_FOUND' does not match '$VDPAU_CACHE_KEY', rebuilding libvdpau"
|
||||
fi
|
||||
fi
|
||||
if [ "$VDPAU_CACHE_OUTDATED" == "1" ]; then
|
||||
buildVdpau
|
||||
sudo echo $VDPAU_CACHE_KEY > "$VDPAU_CACHE_FILE"
|
||||
else
|
||||
info_msg "Using cached libvdpau"
|
||||
fi
|
||||
}
|
||||
|
||||
buildVdpau() {
|
||||
info_msg "Downloading and building libvdpau"
|
||||
|
||||
if [ -d "$EXTERNAL/libvdpau" ]; then
|
||||
rm -rf "$EXTERNAL/libvdpau"
|
||||
fi
|
||||
cd $VDPAU_PATH
|
||||
rm -rf *
|
||||
|
||||
cd "$EXTERNAL"
|
||||
git clone git://anongit.freedesktop.org/vdpau/libvdpau
|
||||
|
||||
cd "$EXTERNAL/libvdpau"
|
||||
./autogen.sh --prefix=$VDPAU_PATH --enable-static
|
||||
make $MAKE_ARGS
|
||||
sudo make install
|
||||
sudo ldconfig
|
||||
}
|
||||
|
||||
getFFmpeg() {
|
||||
travisStartFold "Getting ffmpeg"
|
||||
|
||||
local FFMPEG_CACHE="$CACHE/ffmpeg"
|
||||
local FFMPEG_CACHE_FILE="$FFMPEG_CACHE/.cache.txt"
|
||||
local FFMPEG_CACHE_KEY="${FFMPEG_CACHE_VERSION}"
|
||||
local FFMPEG_CACHE_OUTDATED="1"
|
||||
|
||||
if [ ! -d "$FFMPEG_CACHE" ]; then
|
||||
mkdir -p "$FFMPEG_CACHE"
|
||||
fi
|
||||
|
||||
ln -sf "$FFMPEG_CACHE" "$FFMPEG_PATH"
|
||||
|
||||
if [ -f "$FFMPEG_CACHE_FILE" ]; then
|
||||
local FFMPEG_CACHE_KEY_FOUND=`tail -n 1 $FFMPEG_CACHE_FILE`
|
||||
if [ "$FFMPEG_CACHE_KEY" == "$FFMPEG_CACHE_KEY_FOUND" ]; then
|
||||
FFMPEG_CACHE_OUTDATED="0"
|
||||
else
|
||||
info_msg "Cache key '$FFMPEG_CACHE_KEY_FOUND' does not match '$FFMPEG_CACHE_KEY', rebuilding ffmpeg"
|
||||
fi
|
||||
fi
|
||||
if [ "$FFMPEG_CACHE_OUTDATED" == "1" ]; then
|
||||
buildFFmpeg
|
||||
sudo echo $FFMPEG_CACHE_KEY > "$FFMPEG_CACHE_FILE"
|
||||
else
|
||||
info_msg "Using cached ffmpeg"
|
||||
fi
|
||||
}
|
||||
|
||||
buildFFmpeg() {
|
||||
info_msg "Downloading and building ffmpeg"
|
||||
|
||||
if [ -d "$EXTERNAL/ffmpeg" ]; then
|
||||
rm -rf "$EXTERNAL/ffmpeg"
|
||||
fi
|
||||
cd $FFMPEG_PATH
|
||||
rm -rf *
|
||||
|
||||
cd "$EXTERNAL"
|
||||
git clone https://git.ffmpeg.org/ffmpeg.git
|
||||
|
||||
cd "$EXTERNAL/ffmpeg"
|
||||
./configure \
|
||||
--prefix=$FFMPEG_PATH \
|
||||
--disable-debug \
|
||||
--disable-programs \
|
||||
--disable-doc \
|
||||
--disable-everything \
|
||||
--enable-gpl \
|
||||
--enable-version3 \
|
||||
--enable-libopus \
|
||||
--enable-decoder=aac \
|
||||
--enable-decoder=aac_latm \
|
||||
--enable-decoder=aasc \
|
||||
--enable-decoder=flac \
|
||||
--enable-decoder=gif \
|
||||
--enable-decoder=h264 \
|
||||
--enable-decoder=h264_vdpau \
|
||||
--enable-decoder=mp1 \
|
||||
--enable-decoder=mp1float \
|
||||
--enable-decoder=mp2 \
|
||||
--enable-decoder=mp2float \
|
||||
--enable-decoder=mp3 \
|
||||
--enable-decoder=mp3adu \
|
||||
--enable-decoder=mp3adufloat \
|
||||
--enable-decoder=mp3float \
|
||||
--enable-decoder=mp3on4 \
|
||||
--enable-decoder=mp3on4float \
|
||||
--enable-decoder=mpeg4 \
|
||||
--enable-decoder=mpeg4_vdpau \
|
||||
--enable-decoder=msmpeg4v2 \
|
||||
--enable-decoder=msmpeg4v3 \
|
||||
--enable-decoder=opus \
|
||||
--enable-decoder=vorbis \
|
||||
--enable-decoder=wavpack \
|
||||
--enable-decoder=wmalossless \
|
||||
--enable-decoder=wmapro \
|
||||
--enable-decoder=wmav1 \
|
||||
--enable-decoder=wmav2 \
|
||||
--enable-decoder=wmavoice \
|
||||
--enable-encoder=libopus \
|
||||
--enable-hwaccel=h264_vaapi \
|
||||
--enable-hwaccel=h264_vdpau \
|
||||
--enable-hwaccel=mpeg4_vaapi \
|
||||
--enable-hwaccel=mpeg4_vdpau \
|
||||
--enable-parser=aac \
|
||||
--enable-parser=aac_latm \
|
||||
--enable-parser=flac \
|
||||
--enable-parser=h264 \
|
||||
--enable-parser=mpeg4video \
|
||||
--enable-parser=mpegaudio \
|
||||
--enable-parser=opus \
|
||||
--enable-parser=vorbis \
|
||||
--enable-demuxer=aac \
|
||||
--enable-demuxer=flac \
|
||||
--enable-demuxer=gif \
|
||||
--enable-demuxer=h264 \
|
||||
--enable-demuxer=mov \
|
||||
--enable-demuxer=mp3 \
|
||||
--enable-demuxer=ogg \
|
||||
--enable-demuxer=wav \
|
||||
--enable-muxer=ogg \
|
||||
--enable-muxer=opus
|
||||
make $MAKE_ARGS
|
||||
sudo make install
|
||||
sudo ldconfig
|
||||
}
|
||||
|
||||
getOpenAL() {
|
||||
travisStartFold "Getting openal-soft"
|
||||
|
||||
local OPENAL_CACHE="$CACHE/openal-soft"
|
||||
local OPENAL_CACHE_FILE="$OPENAL_CACHE/.cache.txt"
|
||||
local OPENAL_CACHE_KEY="${OPENAL_CACHE_VERSION}"
|
||||
local OPENAL_CACHE_OUTDATED="1"
|
||||
|
||||
if [ ! -d "$OPENAL_CACHE" ]; then
|
||||
mkdir -p "$OPENAL_CACHE"
|
||||
fi
|
||||
|
||||
ln -sf "$OPENAL_CACHE" "$OPENAL_PATH"
|
||||
|
||||
if [ -f "$OPENAL_CACHE_FILE" ]; then
|
||||
local OPENAL_CACHE_KEY_FOUND=`tail -n 1 $OPENAL_CACHE_FILE`
|
||||
if [ "$OPENAL_CACHE_KEY" == "$OPENAL_CACHE_KEY_FOUND" ]; then
|
||||
OPENAL_CACHE_OUTDATED="0"
|
||||
else
|
||||
info_msg "Cache key '$OPENAL_CACHE_KEY_FOUND' does not match '$OPENAL_CACHE_KEY', rebuilding openal-soft"
|
||||
fi
|
||||
fi
|
||||
if [ "$OPENAL_CACHE_OUTDATED" == "1" ]; then
|
||||
buildOpenAL
|
||||
sudo echo $OPENAL_CACHE_KEY > "$OPENAL_CACHE_FILE"
|
||||
else
|
||||
info_msg "Using cached openal-soft"
|
||||
fi
|
||||
}
|
||||
|
||||
buildOpenAL() {
|
||||
info_msg "Downloading and building openal-soft"
|
||||
|
||||
if [ -d "$EXTERNAL/openal-soft" ]; then
|
||||
rm -rf "$EXTERNAL/openal-soft"
|
||||
fi
|
||||
cd $OPENAL_PATH
|
||||
rm -rf *
|
||||
|
||||
cd "$EXTERNAL"
|
||||
git clone https://github.com/kcat/openal-soft.git
|
||||
|
||||
cd "$EXTERNAL/openal-soft/build"
|
||||
cmake \
|
||||
-D CMAKE_INSTALL_PREFIX=$OPENAL_PATH \
|
||||
-D CMAKE_BUILD_TYPE=Release \
|
||||
-D LIBTYPE=STATIC \
|
||||
..
|
||||
make $MAKE_ARGS
|
||||
sudo make install
|
||||
sudo ldconfig
|
||||
}
|
||||
|
||||
getBreakpad() {
|
||||
travisStartFold "Getting breakpad"
|
||||
travisStartFold "Getting breakpad"
|
||||
|
||||
local BREAKPAD_CACHE="$CACHE/breakpad"
|
||||
local BREAKPAD_CACHE_FILE="$BREAKPAD_CACHE/.cache.txt"
|
||||
|
||||
if [ ! -d "$BREAKPAD_CACHE" ]; then
|
||||
mkdir -p "$BREAKPAD_CACHE"
|
||||
fi
|
||||
local BREAKPAD_CACHE="$CACHE/breakpad"
|
||||
local BREAKPAD_CACHE_FILE="$BREAKPAD_CACHE/.cache.txt"
|
||||
local BREAKPAD_CACHE_KEY="${BREAKPAD_CACHE_VERSION}"
|
||||
local BREAKPAD_CACHE_OUTDATED="1"
|
||||
|
||||
ln -sf "$BREAKPAD_CACHE" "$BREAKPAD_PATH"
|
||||
if [ ! -d "$BREAKPAD_CACHE" ]; then
|
||||
mkdir -p "$BREAKPAD_CACHE"
|
||||
fi
|
||||
|
||||
if [ -f "$BREAKPAD_CACHE_FILE" ]; then
|
||||
info_msg "Using cached breakpad"
|
||||
makeBreakpadLink
|
||||
ln -sf "$BREAKPAD_CACHE" "$BREAKPAD_PATH"
|
||||
|
||||
if [ -f "$BREAKPAD_CACHE_FILE" ]; then
|
||||
local BREAKPAD_CACHE_KEY_FOUND=`tail -n 1 $BREAKPAD_CACHE_FILE`
|
||||
if [ "$BREAKPAD_CACHE_KEY" == "$BREAKPAD_CACHE_KEY_FOUND" ]; then
|
||||
BREAKPAD_CACHE_OUTDATED="0"
|
||||
else
|
||||
buildBreakpad
|
||||
sudo touch "$BREAKPAD_CACHE_FILE"
|
||||
info_msg "Cache key '$BREAKPAD_CACHE_KEY_FOUND' does not match '$BREAKPAD_CACHE_KEY', rebuilding breakpad"
|
||||
fi
|
||||
fi
|
||||
if [ "$BREAKPAD_CACHE_OUTDATED" == "1" ]; then
|
||||
buildBreakpad
|
||||
sudo echo $BREAKPAD_CACHE_KEY > "$BREAKPAD_CACHE_FILE"
|
||||
else
|
||||
info_msg "Using cached breakpad"
|
||||
fi
|
||||
}
|
||||
|
||||
buildBreakpad() {
|
||||
info_msg "Downloading and building breakpad"
|
||||
info_msg "Downloading and building breakpad"
|
||||
|
||||
cd "$EXTERNAL"
|
||||
git clone https://chromium.googlesource.com/breakpad/breakpad
|
||||
if [ -d "$EXTERNAL/breakpad" ]; then
|
||||
rm -rf "$EXTERNAL/breakpad"
|
||||
fi
|
||||
cd $BREAKPAD_PATH
|
||||
rm -rf *
|
||||
|
||||
makeBreakpadLink
|
||||
cd "$BREAKPAD_PATH"
|
||||
./configure
|
||||
make $MAKE_ARGS
|
||||
}
|
||||
cd "$EXTERNAL"
|
||||
git clone https://chromium.googlesource.com/breakpad/breakpad
|
||||
|
||||
makeBreakpadLink() {
|
||||
local LSS_PATH="$BREAKPAD_PATH/src/third_party/lss"
|
||||
ln -s -f "$EXTERNAL/linux-syscall-support" "$LSS_PATH"
|
||||
|
||||
local LSS_GIT_PATH="$LSS_PATH/.git"
|
||||
|
||||
if [ -d "$LSS_GIT_PATH" ]; then # Remove git dir to prevent cache changes
|
||||
rm -rf "$LSS_GIT_PATH"
|
||||
fi
|
||||
cd "$EXTERNAL/breakpad/src/third_party"
|
||||
git clone https://chromium.googlesource.com/linux-syscall-support lss
|
||||
|
||||
cd "$EXTERNAL/breakpad"
|
||||
./configure --prefix=$BREAKPAD_PATH
|
||||
make $MAKE_ARGS
|
||||
sudo make install
|
||||
sudo ldconfig
|
||||
}
|
||||
|
||||
getCustomQt() {
|
||||
travisStartFold "Getting patched QT"
|
||||
travisStartFold "Getting patched Qt"
|
||||
|
||||
local QT_CACHE="$CACHE/qtPatched"
|
||||
local QT_CACHE_FILE="$QT_CACHE/.cache.txt"
|
||||
local QT_CACHE="$CACHE/qtPatched"
|
||||
local QT_CACHE_FILE="$QT_CACHE/.cache.txt"
|
||||
local QT_PATCH_CHECKSUM=`sha1sum $QT_PATCH`
|
||||
local QT_CACHE_KEY="${QT_VERSION}_${QT_CACHE_VERSION}_${QT_PATCH_CHECKSUM:0:32}"
|
||||
local QT_CACHE_OUTDATED="1"
|
||||
|
||||
if [ ! -d "$QT_CACHE" ]; then
|
||||
mkdir -p "$QT_CACHE"
|
||||
fi
|
||||
if [ ! -d "$QT_CACHE" ]; then
|
||||
mkdir -p "$QT_CACHE"
|
||||
fi
|
||||
|
||||
ln -sf "$QT_CACHE" "$QT_PATH"
|
||||
ln -sf "$QT_CACHE" "$QT_PATH"
|
||||
|
||||
if [ -f "$QT_CACHE_FILE" ]; then
|
||||
info_msg "Using cached patched qt"
|
||||
if [ -f "$QT_CACHE_FILE" ]; then
|
||||
local QT_CACHE_KEY_FOUND=`tail -n 1 $QT_CACHE_FILE`
|
||||
if [ "$QT_CACHE_KEY" == "$QT_CACHE_KEY_FOUND" ]; then
|
||||
QT_CACHE_OUTDATED="0"
|
||||
else
|
||||
buildCustomQt
|
||||
sudo touch "$QT_CACHE_FILE"
|
||||
info_msg "Cache key '$QT_CACHE_KEY_FOUND' does not match '$QT_CACHE_KEY', rebuilding patched Qt"
|
||||
fi
|
||||
fi
|
||||
if [ "$QT_CACHE_OUTDATED" == "1" ]; then
|
||||
buildCustomQt
|
||||
sudo echo $QT_CACHE_KEY > "$QT_CACHE_FILE"
|
||||
else
|
||||
info_msg "Using cached patched Qt"
|
||||
fi
|
||||
|
||||
export PATH="$QT_PATH/bin:$PATH"
|
||||
export PATH="$QT_PATH/bin:$PATH"
|
||||
}
|
||||
|
||||
buildCustomQt() {
|
||||
info_msg "Downloading and building patched qt"
|
||||
info_msg "Downloading and building patched qt"
|
||||
|
||||
cd "$EXTERNAL"
|
||||
echo -e "Clone Qt ${QT_VERSION}\n"
|
||||
git clone git://code.qt.io/qt/qt5.git qt${QT_VERSION}
|
||||
cd qt${QT_VERSION}
|
||||
git checkout "$(echo ${QT_VERSION} | sed -e s/\..$//)"
|
||||
perl init-repository --module-subset=qtbase,qtimageformats
|
||||
git checkout v${QT_VERSION}
|
||||
cd qtbase && git checkout v${QT_VERSION} && cd ..
|
||||
cd qtimageformats && git checkout v${QT_VERSION} && cd ..
|
||||
cd ..
|
||||
if [ -d "$EXTERNAL/qt${QT_VERSION}" ]; then
|
||||
rm -rf "$EXTERNAL/qt${QT_VERSION}"
|
||||
fi
|
||||
cd $QT_PATH
|
||||
rm -rf *
|
||||
|
||||
cd "$EXTERNAL/qt${QT_VERSION}/qtbase"
|
||||
git apply "$UPSTREAM/Telegram/Patches/qtbase_${QT_VERSION//\./_}.diff"
|
||||
cd ..
|
||||
./configure -prefix "$QT_PATH" -release -opensource -confirm-license -qt-zlib \
|
||||
-qt-libpng -qt-libjpeg -qt-freetype -qt-harfbuzz -qt-pcre -qt-xcb \
|
||||
-qt-xkbcommon-x11 -no-opengl -static -nomake examples -nomake tests \
|
||||
-dbus-runtime -openssl-linked -no-gstreamer -no-mtdev # <- Not sure about these
|
||||
make $MAKE_ARGS
|
||||
sudo make install
|
||||
cd "$EXTERNAL"
|
||||
git clone git://code.qt.io/qt/qt5.git qt${QT_VERSION}
|
||||
|
||||
cd "$EXTERNAL/qt${QT_VERSION}"
|
||||
git checkout "$(echo ${QT_VERSION} | sed -e s/\..$//)"
|
||||
perl init-repository --module-subset=qtbase,qtimageformats
|
||||
git checkout v${QT_VERSION}
|
||||
cd qtbase && git checkout v${QT_VERSION} && cd ..
|
||||
cd qtimageformats && git checkout v${QT_VERSION} && cd ..
|
||||
|
||||
cd "$EXTERNAL/qt${QT_VERSION}/qtbase"
|
||||
git apply "$QT_PATCH"
|
||||
cd ..
|
||||
|
||||
./configure -prefix $QT_PATH -release -opensource -confirm-license -qt-zlib \
|
||||
-qt-libpng -qt-libjpeg -qt-freetype -qt-harfbuzz -qt-pcre -qt-xcb \
|
||||
-qt-xkbcommon-x11 -no-opengl -no-gtkstyle -static \
|
||||
-nomake examples -nomake tests \
|
||||
-dbus-runtime -no-gstreamer -no-mtdev # <- Not sure about these
|
||||
make $MAKE_ARGS
|
||||
sudo make install
|
||||
}
|
||||
|
||||
getGYP() {
|
||||
travisStartFold "Getting patched GYP"
|
||||
|
||||
local GYP_CACHE="$CACHE/gyp"
|
||||
local GYP_CACHE_FILE="$GYP_CACHE/.cache.txt"
|
||||
local GYP_PATCH_CHECKSUM=`sha1sum $GYP_PATCH`
|
||||
local GYP_CACHE_KEY="${GYP_CACHE_VERSION}_${GYP_PATCH_CHECKSUM:0:32}"
|
||||
local GYP_CACHE_OUTDATED="1"
|
||||
|
||||
if [ ! -d "$GYP_CACHE" ]; then
|
||||
mkdir -p "$GYP_CACHE"
|
||||
fi
|
||||
|
||||
ln -sf "$GYP_CACHE" "$GYP_PATH"
|
||||
|
||||
if [ -f "$GYP_CACHE_FILE" ]; then
|
||||
local GYP_CACHE_KEY_FOUND=`tail -n 1 $GYP_CACHE_FILE`
|
||||
if [ "$GYP_CACHE_KEY" == "$GYP_CACHE_KEY_FOUND" ]; then
|
||||
GYP_CACHE_OUTDATED="0"
|
||||
else
|
||||
info_msg "Cache key '$GYP_CACHE_KEY_FOUND' does not match '$GYP_CACHE_KEY', rebuilding patched GYP"
|
||||
fi
|
||||
fi
|
||||
if [ "$GYP_CACHE_OUTDATED" == "1" ]; then
|
||||
buildGYP
|
||||
sudo echo $GYP_CACHE_KEY > "$GYP_CACHE_FILE"
|
||||
else
|
||||
info_msg "Using cached patched GYP"
|
||||
fi
|
||||
}
|
||||
|
||||
buildGYP() {
|
||||
info_msg "Downloading and building patched GYP"
|
||||
|
||||
if [ -d "$EXTERNAL/gyp" ]; then
|
||||
rm -rf "$EXTERNAL/gyp"
|
||||
fi
|
||||
cd $GYP_PATH
|
||||
rm -rf *
|
||||
|
||||
cd "$EXTERNAL"
|
||||
git clone https://chromium.googlesource.com/external/gyp
|
||||
|
||||
cd "$EXTERNAL/gyp"
|
||||
git checkout 702ac58e4772
|
||||
git apply "$GYP_PATCH"
|
||||
cp -r * "$GYP_PATH/"
|
||||
}
|
||||
|
||||
buildTelegram() {
|
||||
info_msg "Build codegen_style"
|
||||
# Build codegen_style
|
||||
mkdir -p "$UPSTREAM/Linux/obj/codegen_style/Debug"
|
||||
cd "$UPSTREAM/Linux/obj/codegen_style/Debug"
|
||||
qmake QT_TDESKTOP_PATH="${QT_PATH}" QT_TDESKTOP_VERSION=${QT_VERSION} CONFIG+=debug "../../../../Telegram/build/qmake/codegen_style/codegen_style.pro"
|
||||
make $MAKE_ARGS
|
||||
travisStartFold "Build tdesktop"
|
||||
|
||||
info_msg "Build codegen_numbers"
|
||||
# Build codegen_numbers
|
||||
mkdir -p "$UPSTREAM/Linux/obj/codegen_numbers/Debug"
|
||||
cd "$UPSTREAM/Linux/obj/codegen_numbers/Debug"
|
||||
qmake QT_TDESKTOP_PATH="${QT_PATH}" QT_TDESKTOP_VERSION=${QT_VERSION} CONFIG+=debug "../../../../Telegram/build/qmake/codegen_numbers/codegen_numbers.pro"
|
||||
make $MAKE_ARGS
|
||||
cd "$UPSTREAM/Telegram/gyp"
|
||||
"$GYP_PATH/gyp" \
|
||||
-Dtravis_defines=${GYP_DEFINES:1} \
|
||||
-Dlinux_path_xkbcommon=$XKB_PATH \
|
||||
-Dlinux_path_va=$VA_PATH \
|
||||
-Dlinux_path_ffmpeg=$FFMPEG_PATH \
|
||||
-Dlinux_path_openal=$OPENAL_PATH \
|
||||
-Dlinux_path_qt=$QT_PATH \
|
||||
-Dlinux_path_breakpad=$BREAKPAD_PATH \
|
||||
-Dlinux_path_libexif_lib=/usr/local/lib \
|
||||
-Dlinux_lib_ssl=-lssl \
|
||||
-Dlinux_lib_crypto=-lcrypto \
|
||||
-Dlinux_lib_icu=-licuuc\ -licutu\ -licui18n \
|
||||
--depth=. --generator-output=../.. --format=cmake -Goutput_dir=out \
|
||||
Telegram.gyp
|
||||
cd "$UPSTREAM/out/Debug"
|
||||
|
||||
info_msg "Build MetaLang"
|
||||
# Build MetaLang
|
||||
mkdir -p "$UPSTREAM/Linux/DebugIntermediateLang"
|
||||
cd "$UPSTREAM/Linux/DebugIntermediateLang"
|
||||
qmake QT_TDESKTOP_PATH="${QT_PATH}" QT_TDESKTOP_VERSION=${QT_VERSION} CONFIG+=debug "../../Telegram/MetaLang.pro"
|
||||
make $MAKE_ARGS
|
||||
|
||||
info_msg "Build Telegram Desktop"
|
||||
# Build Telegram Desktop
|
||||
mkdir -p "$UPSTREAM/Linux/DebugIntermediate"
|
||||
cd "$UPSTREAM/Linux/DebugIntermediate"
|
||||
|
||||
./../codegen/Debug/codegen_style "-I./../../Telegram/Resources" "-I./../../Telegram/SourceFiles" "-o./GeneratedFiles/styles" all_files.style --rebuild
|
||||
./../codegen/Debug/codegen_numbers "-o./GeneratedFiles" "./../../Telegram/Resources/numbers.txt"
|
||||
./../DebugLang/MetaLang -lang_in ./../../Telegram/Resources/langs/lang.strings -lang_out ./GeneratedFiles/lang_auto
|
||||
qmake QT_TDESKTOP_PATH="${QT_PATH}" QT_TDESKTOP_VERSION=${QT_VERSION} CONFIG+=debug "../../Telegram/Telegram.pro"
|
||||
make $MAKE_ARGS
|
||||
export ASM="gcc"
|
||||
cmake .
|
||||
make $MAKE_ARGS
|
||||
}
|
||||
|
||||
check() {
|
||||
local filePath="$UPSTREAM/Linux/Debug/Telegram"
|
||||
if test -f "$filePath"; then
|
||||
success_msg "Build successful done! :)"
|
||||
local filePath="$UPSTREAM/out/Debug/Telegram"
|
||||
if test -f "$filePath"; then
|
||||
success_msg "Build successful done! :)"
|
||||
|
||||
local size;
|
||||
size=$(stat -c %s "$filePath")
|
||||
success_msg "File size of ${filePath}: ${size} Bytes"
|
||||
else
|
||||
error_msg "Build error, output file does not exist"
|
||||
exit 1
|
||||
fi
|
||||
local size;
|
||||
size=$(stat -c %s "$filePath")
|
||||
success_msg "File size of ${filePath}: ${size} Bytes"
|
||||
else
|
||||
error_msg "Build error, output file does not exist"
|
||||
exit 1
|
||||
fi
|
||||
}
|
||||
|
||||
source ./.travis/common.sh
|
||||
|
||||
14
README.md
@@ -2,6 +2,7 @@
|
||||
|
||||
This is the complete source code and the build instructions for the alpha version of the official desktop client for the [Telegram][telegram] messenger, based on the [Telegram API][telegram_api] and the [MTProto][telegram_proto] secure protocol.
|
||||
|
||||
[](https://badge.fury.io/gh/telegramdesktop%2Ftdesktop)
|
||||
[](https://travis-ci.org/telegramdesktop/tdesktop)
|
||||
|
||||
The source code is published under GPLv3 with OpenSSL exception, the license is available [here][license].
|
||||
@@ -12,11 +13,11 @@ The source code is published under GPLv3 with OpenSSL exception, the license is
|
||||
* Mac OS X 10.8 - Mac OS X 10.11
|
||||
* Mac OS X 10.6 - Mac OS X 10.7 (separate build)
|
||||
* Ubuntu 12.04 - Ubuntu 16.04
|
||||
* Fedora 22
|
||||
* Fedora 22 - Fedora 24
|
||||
|
||||
## Third-party
|
||||
|
||||
* Qt 5.3.2 and 5.6.0, slightly patched ([LGPL](http://doc.qt.io/qt-5/lgpl.html))
|
||||
* Qt 5.3.2 and 5.6.2, slightly patched ([LGPL](http://doc.qt.io/qt-5/lgpl.html))
|
||||
* OpenSSL 1.0.1g ([OpenSSL License](https://www.openssl.org/source/license.html))
|
||||
* zlib 1.2.8 ([zlib License](http://www.zlib.net/zlib_license.html))
|
||||
* libexif 0.6.20 ([LGPL](https://www.gnu.org/licenses/old-licenses/lgpl-2.1.en.html))
|
||||
@@ -34,10 +35,8 @@ The source code is published under GPLv3 with OpenSSL exception, the license is
|
||||
## Build instructions
|
||||
|
||||
* [Visual Studio 2015][msvc]
|
||||
* [Xcode 7][xcode]
|
||||
* [Xcode 7 for OS X 10.6 and 10.7][xcode_old]
|
||||
* [Qt Creator 3.5.1 Ubuntu][qtcreator]
|
||||
* [Using qmake on GNU/Linux][qmake]
|
||||
* [Xcode 8][xcode]
|
||||
* [GYP/CMake on GNU/Linux][cmake]
|
||||
|
||||
## Projects in Telegram solution
|
||||
|
||||
@@ -83,5 +82,4 @@ The source code is published under GPLv3 with OpenSSL exception, the license is
|
||||
[msvc]: doc/building-msvc.md
|
||||
[xcode]: doc/building-xcode.md
|
||||
[xcode_old]: doc/building-xcode-old.md
|
||||
[qtcreator]: doc/building-qtcreator.md
|
||||
[qmake]: doc/building-qmake.md
|
||||
[cmake]: doc/building-cmake.md
|
||||
|
||||
@@ -1,30 +0,0 @@
|
||||
QT += core
|
||||
|
||||
CONFIG(debug, debug|release) {
|
||||
DEFINES += _DEBUG
|
||||
OBJECTS_DIR = ./../DebugIntermediateEmoji
|
||||
MOC_DIR = ./GeneratedFiles/Debug
|
||||
DESTDIR = ./../DebugEmoji
|
||||
}
|
||||
CONFIG(release, debug|release) {
|
||||
OBJECTS_DIR = ./../ReleaseIntermediateEmoji
|
||||
MOC_DIR = ./GeneratedFiles/Release
|
||||
DESTDIR = ./../ReleaseEmoji
|
||||
}
|
||||
|
||||
CONFIG += plugin static
|
||||
|
||||
macx {
|
||||
QMAKE_INFO_PLIST = ./SourceFiles/_other/Emoji.plist
|
||||
QMAKE_LFLAGS += -framework Cocoa
|
||||
}
|
||||
|
||||
SOURCES += \
|
||||
./SourceFiles/_other/memain.cpp \
|
||||
./SourceFiles/_other/genemoji.cpp \
|
||||
|
||||
HEADERS += \
|
||||
./SourceFiles/_other/memain.h \
|
||||
./SourceFiles/_other/genemoji.h \
|
||||
|
||||
include(qt_static.pri)
|
||||
@@ -1,30 +0,0 @@
|
||||
QT += core
|
||||
|
||||
CONFIG(debug, debug|release) {
|
||||
DEFINES += _DEBUG
|
||||
OBJECTS_DIR = ./../DebugIntermediateLang
|
||||
MOC_DIR = ./GeneratedFiles/Debug
|
||||
DESTDIR = ./../DebugLang
|
||||
}
|
||||
CONFIG(release, debug|release) {
|
||||
OBJECTS_DIR = ./../ReleaseIntermediateLang
|
||||
MOC_DIR = ./GeneratedFiles/Release
|
||||
DESTDIR = ./../ReleaseLang
|
||||
}
|
||||
|
||||
CONFIG += plugin static c++14
|
||||
|
||||
macx {
|
||||
QMAKE_INFO_PLIST = ./SourceFiles/_other/Lang.plist
|
||||
QMAKE_LFLAGS += -framework Cocoa
|
||||
}
|
||||
|
||||
SOURCES += \
|
||||
./SourceFiles/_other/mlmain.cpp \
|
||||
./SourceFiles/_other/genlang.cpp \
|
||||
|
||||
HEADERS += \
|
||||
./SourceFiles/_other/mlmain.h \
|
||||
./SourceFiles/_other/genlang.h \
|
||||
|
||||
include(qt_static.pri)
|
||||
@@ -1,40 +0,0 @@
|
||||
QT += core
|
||||
|
||||
CONFIG(debug, debug|release) {
|
||||
DEFINES += _DEBUG
|
||||
OBJECTS_DIR = ./../DebugIntermediatePacker
|
||||
MOC_DIR = ./GeneratedFiles/Debug
|
||||
DESTDIR = ./../Debug
|
||||
}
|
||||
CONFIG(release, debug|release) {
|
||||
OBJECTS_DIR = ./../ReleaseIntermediatePacker
|
||||
MOC_DIR = ./GeneratedFiles/Release
|
||||
DESTDIR = ./../Release
|
||||
}
|
||||
|
||||
macx {
|
||||
QMAKE_INFO_PLIST = ./SourceFiles/_other/Packer.plist
|
||||
QMAKE_LFLAGS += -framework Cocoa
|
||||
}
|
||||
|
||||
SOURCES += \
|
||||
./SourceFiles/_other/packer.cpp \
|
||||
|
||||
HEADERS += \
|
||||
./SourceFiles/_other/packer.h \
|
||||
|
||||
unix {
|
||||
linux-g++:QMAKE_TARGET.arch = $$QMAKE_HOST.arch
|
||||
linux-g++-32:QMAKE_TARGET.arch = x86
|
||||
linux-g++-64:QMAKE_TARGET.arch = x86_64
|
||||
|
||||
contains(QMAKE_TARGET.arch, x86_64) {
|
||||
DEFINES += Q_OS_LINUX64
|
||||
} else {
|
||||
DEFINES += Q_OS_LINUX32
|
||||
}
|
||||
}
|
||||
|
||||
include(qt_static.pri)
|
||||
|
||||
LIBS += -lcrypto -lssl -lz -llzma
|
||||
@@ -1,5 +1,33 @@
|
||||
diff --git a/pylib/gyp/generator/cmake.py b/pylib/gyp/generator/cmake.py
|
||||
index a2b9629..68d7020 100644
|
||||
--- a/pylib/gyp/generator/cmake.py
|
||||
+++ b/pylib/gyp/generator/cmake.py
|
||||
@@ -1070,6 +1070,23 @@ def WriteTarget(namer, qualified_target, target_dicts, build_dir, config_to_use,
|
||||
|
||||
output.write(')\n')
|
||||
|
||||
+ # Precompile header
|
||||
+ precompiled_header = config.get('cmake_precompiled_header', '')
|
||||
+ if precompiled_header:
|
||||
+ precompiled_header_script = config.get('cmake_precompiled_header_script', '')
|
||||
+ if not precompiled_header_script:
|
||||
+ print ('ERROR: cmake_precompiled_header requires cmake_precompiled_header_script')
|
||||
+ cmake_precompiled_header = NormjoinPath(path_from_cmakelists_to_gyp, precompiled_header)
|
||||
+ cmake_precompiled_header_script = NormjoinPathForceCMakeSource(path_from_cmakelists_to_gyp, precompiled_header_script)
|
||||
+ output.write('include(')
|
||||
+ output.write(cmake_precompiled_header_script)
|
||||
+ output.write(')\n')
|
||||
+ output.write('add_precompiled_header(')
|
||||
+ output.write(cmake_target_name)
|
||||
+ output.write(' ')
|
||||
+ output.write(cmake_precompiled_header)
|
||||
+ output.write(')\n')
|
||||
+
|
||||
UnsetVariable(output, 'TOOLSET')
|
||||
UnsetVariable(output, 'TARGET')
|
||||
|
||||
diff --git a/pylib/gyp/generator/xcode.py b/pylib/gyp/generator/xcode.py
|
||||
index 0e3fb93..0679660 100644
|
||||
index db99d6a..f8398cc 100644
|
||||
--- a/pylib/gyp/generator/xcode.py
|
||||
+++ b/pylib/gyp/generator/xcode.py
|
||||
@@ -72,6 +72,10 @@ generator_additional_non_configuration_keys = [
|
||||
@@ -13,7 +41,7 @@ index 0e3fb93..0679660 100644
|
||||
'mac_bundle',
|
||||
'mac_bundle_resources',
|
||||
'mac_framework_headers',
|
||||
@@ -761,6 +765,26 @@ def GenerateOutput(target_list, target_dicts, data, params):
|
||||
@@ -772,6 +776,26 @@ def GenerateOutput(target_list, target_dicts, data, params):
|
||||
xcode_targets[qualified_target] = xct
|
||||
xcode_target_to_target_dict[xct] = spec
|
||||
|
||||
|
||||
744
Telegram/Patches/qtbase_5_3_2.diff
Normal file
@@ -0,0 +1,744 @@
|
||||
diff --git a/configure b/configure
|
||||
index cb8d78f..cadb3f0 100755
|
||||
--- a/configure
|
||||
+++ b/configure
|
||||
@@ -511,7 +511,8 @@ if [ "$BUILD_ON_MAC" = "yes" ]; then
|
||||
exit 2
|
||||
fi
|
||||
|
||||
- if ! /usr/bin/xcrun -find xcrun >/dev/null 2>&1; then
|
||||
+ # Patch: Fix Qt for working with Xcode 8.
|
||||
+ if ! /usr/bin/xcrun -find xcodebuild >/dev/null 2>&1; then
|
||||
echo >&2
|
||||
echo " Xcode not set up properly. You may need to confirm the license" >&2
|
||||
echo " agreement by running /usr/bin/xcodebuild without arguments." >&2
|
||||
diff --git a/mkspecs/common/g++-macx.conf b/mkspecs/common/g++-macx.conf
|
||||
index 086510d..ae4f81a 100644
|
||||
--- a/mkspecs/common/g++-macx.conf
|
||||
+++ b/mkspecs/common/g++-macx.conf
|
||||
@@ -14,7 +14,8 @@ QMAKE_CFLAGS_RELEASE_WITH_DEBUGINFO += -gdwarf-2
|
||||
QMAKE_CXXFLAGS_RELEASE_WITH_DEBUGINFO += -gdwarf-2
|
||||
QMAKE_LFLAGS_RELEASE_WITH_DEBUGINFO += -g -gdwarf-2
|
||||
|
||||
-QMAKE_LFLAGS_STATIC_LIB += -all_load
|
||||
+# Patch: Don't remember :(
|
||||
+#QMAKE_LFLAGS_STATIC_LIB += -all_load
|
||||
|
||||
QMAKE_XCODE_GCC_VERSION = com.apple.compilers.llvmgcc42
|
||||
|
||||
diff --git a/mkspecs/features/mac/default_pre.prf b/mkspecs/features/mac/default_pre.prf
|
||||
index 0cc8cd6..ca9725b 100644
|
||||
--- a/mkspecs/features/mac/default_pre.prf
|
||||
+++ b/mkspecs/features/mac/default_pre.prf
|
||||
@@ -12,7 +12,9 @@ isEmpty(QMAKE_XCODE_DEVELOPER_PATH) {
|
||||
error("Xcode is not installed in $${QMAKE_XCODE_DEVELOPER_PATH}. Please use xcode-select to choose Xcode installation path.")
|
||||
|
||||
# Make sure Xcode is set up properly
|
||||
- isEmpty($$list($$system("/usr/bin/xcrun -find xcrun 2>/dev/null"))): \
|
||||
+
|
||||
+ # Patch: Fix Qt for working with Xcode 8.
|
||||
+ isEmpty($$list($$system("/usr/bin/xcrun -find xcodebuild 2>/dev/null"))): \
|
||||
error("Xcode not set up properly. You may need to confirm the license agreement by running /usr/bin/xcodebuild.")
|
||||
}
|
||||
|
||||
diff --git a/src/gui/image/qbmphandler.cpp b/src/gui/image/qbmphandler.cpp
|
||||
index bb79a13..5d595bc 100644
|
||||
--- a/src/gui/image/qbmphandler.cpp
|
||||
+++ b/src/gui/image/qbmphandler.cpp
|
||||
@@ -220,6 +220,10 @@ static bool read_dib_body(QDataStream &s, const BMP_INFOHDR &bi, int offset, int
|
||||
int blue_scale = 0;
|
||||
int alpha_scale = 0;
|
||||
|
||||
+ // Patch: Backport a fix for bmp reader.
|
||||
+ if (!d->isSequential())
|
||||
+ d->seek(startpos + BMP_FILEHDR_SIZE + (bi.biSize >= BMP_WIN4? BMP_WIN : bi.biSize)); // goto start of colormap
|
||||
+
|
||||
if (bi.biSize >= BMP_WIN4 || (comp == BMP_BITFIELDS && (nbits == 16 || nbits == 32))) {
|
||||
if (d->read((char *)&red_mask, sizeof(red_mask)) != sizeof(red_mask))
|
||||
return false;
|
||||
@@ -307,8 +311,9 @@ static bool read_dib_body(QDataStream &s, const BMP_INFOHDR &bi, int offset, int
|
||||
image.setDotsPerMeterX(bi.biXPelsPerMeter);
|
||||
image.setDotsPerMeterY(bi.biYPelsPerMeter);
|
||||
|
||||
- if (!d->isSequential())
|
||||
- d->seek(startpos + BMP_FILEHDR_SIZE + (bi.biSize >= BMP_WIN4? BMP_WIN : bi.biSize)); // goto start of colormap
|
||||
+ // Patch: Backport a fix for bmp reader.
|
||||
+ //if (!d->isSequential())
|
||||
+ // d->seek(startpos + BMP_FILEHDR_SIZE + (bi.biSize >= BMP_WIN4? BMP_WIN : bi.biSize)); // goto start of colormap
|
||||
|
||||
if (ncols > 0) { // read color table
|
||||
uchar rgb[4];
|
||||
diff --git a/src/gui/painting/qpaintengine_p.h b/src/gui/painting/qpaintengine_p.h
|
||||
index ebff950..4300ca4 100644
|
||||
--- a/src/gui/painting/qpaintengine_p.h
|
||||
+++ b/src/gui/painting/qpaintengine_p.h
|
||||
@@ -87,8 +87,18 @@ public:
|
||||
if (hasSystemTransform) {
|
||||
if (systemTransform.type() <= QTransform::TxTranslate)
|
||||
systemClip.translate(qRound(systemTransform.dx()), qRound(systemTransform.dy()));
|
||||
- else
|
||||
+ // Patch: Transform the system clip region back from device pixels to device-independent pixels before
|
||||
+ // applying systemTransform, which already has transform from device-independent pixels to device pixels.
|
||||
+ else {
|
||||
+#ifdef Q_OS_MAC
|
||||
+ QTransform scaleTransform;
|
||||
+ const qreal invDevicePixelRatio = 1. / pdev->devicePixelRatio();
|
||||
+ scaleTransform.scale(invDevicePixelRatio, invDevicePixelRatio);
|
||||
+ systemClip = systemTransform.map(scaleTransform.map(systemClip));
|
||||
+#else
|
||||
systemClip = systemTransform.map(systemClip);
|
||||
+#endif
|
||||
+ }
|
||||
}
|
||||
|
||||
// Make sure we're inside the viewport.
|
||||
diff --git a/src/gui/text/qtextlayout.cpp b/src/gui/text/qtextlayout.cpp
|
||||
index 4879ae5..56cdcba 100644
|
||||
--- a/src/gui/text/qtextlayout.cpp
|
||||
+++ b/src/gui/text/qtextlayout.cpp
|
||||
@@ -654,6 +654,9 @@ int QTextLayout::nextCursorPosition(int oldPos, CursorMode mode) const
|
||||
while (oldPos < len && !attributes[oldPos].graphemeBoundary)
|
||||
oldPos++;
|
||||
} else {
|
||||
+ // Patch: Skip to the end of the current word, not to the start of the next one.
|
||||
+ while (oldPos < len && attributes[oldPos].whiteSpace)
|
||||
+ oldPos++;
|
||||
if (oldPos < len && d->atWordSeparator(oldPos)) {
|
||||
oldPos++;
|
||||
while (oldPos < len && d->atWordSeparator(oldPos))
|
||||
@@ -662,8 +665,9 @@ int QTextLayout::nextCursorPosition(int oldPos, CursorMode mode) const
|
||||
while (oldPos < len && !d->atSpace(oldPos) && !d->atWordSeparator(oldPos))
|
||||
oldPos++;
|
||||
}
|
||||
- while (oldPos < len && d->atSpace(oldPos))
|
||||
- oldPos++;
|
||||
+ // Patch: Skip to the end of the current word, not to the start of the next one.
|
||||
+ //while (oldPos < len && d->atSpace(oldPos))
|
||||
+ // oldPos++;
|
||||
}
|
||||
|
||||
return oldPos;
|
||||
@@ -1602,6 +1606,9 @@ namespace {
|
||||
int currentPosition;
|
||||
glyph_t previousGlyph;
|
||||
|
||||
+ // Patch: Backport a crash fix.
|
||||
+ QFontEngine *previousGlyphFontEngine;
|
||||
+
|
||||
QFixed minw;
|
||||
QFixed softHyphenWidth;
|
||||
QFixed rightBearing;
|
||||
@@ -1634,13 +1641,19 @@ namespace {
|
||||
if (currentPosition > 0 &&
|
||||
logClusters[currentPosition - 1] < glyphs.numGlyphs) {
|
||||
previousGlyph = currentGlyph(); // needed to calculate right bearing later
|
||||
+
|
||||
+ // Patch: Backport a crash fix.
|
||||
+ previousGlyphFontEngine = fontEngine;
|
||||
}
|
||||
}
|
||||
|
||||
- inline void adjustRightBearing(glyph_t glyph)
|
||||
+ // Patch: Backport a crash fix.
|
||||
+ inline void adjustRightBearing(QFontEngine *engine, glyph_t glyph)
|
||||
{
|
||||
qreal rb;
|
||||
- fontEngine->getGlyphBearings(glyph, 0, &rb);
|
||||
+
|
||||
+ // Patch: Backport a crash fix.
|
||||
+ engine->getGlyphBearings(glyph, 0, &rb);
|
||||
rightBearing = qMin(QFixed(), QFixed::fromReal(rb));
|
||||
}
|
||||
|
||||
@@ -1648,13 +1661,16 @@ namespace {
|
||||
{
|
||||
if (currentPosition <= 0)
|
||||
return;
|
||||
- adjustRightBearing(currentGlyph());
|
||||
+
|
||||
+ // Patch: Backport a crash fix.
|
||||
+ adjustRightBearing(fontEngine, currentGlyph());
|
||||
}
|
||||
|
||||
inline void adjustPreviousRightBearing()
|
||||
{
|
||||
if (previousGlyph > 0)
|
||||
- adjustRightBearing(previousGlyph);
|
||||
+ // Patch: Backport a crash fix.
|
||||
+ adjustRightBearing(previousGlyphFontEngine, previousGlyph);
|
||||
}
|
||||
|
||||
inline void resetRightBearing()
|
||||
diff --git a/src/gui/text/qtextlayout.h b/src/gui/text/qtextlayout.h
|
||||
index cbe42c3..b273db7 100644
|
||||
--- a/src/gui/text/qtextlayout.h
|
||||
+++ b/src/gui/text/qtextlayout.h
|
||||
@@ -194,6 +194,9 @@ private:
|
||||
QRectF *brect, int tabstops, int* tabarray, int tabarraylen,
|
||||
QPainter *painter);
|
||||
QTextEngine *d;
|
||||
+
|
||||
+ // Patch: Give access to the internal api.
|
||||
+ friend class TextBlock;
|
||||
};
|
||||
|
||||
|
||||
diff --git a/src/platformsupport/fontdatabases/mac/qcoretextfontdatabase.mm b/src/platformsupport/fontdatabases/mac/qcoretextfontdatabase.mm
|
||||
index ca7afb7..25ae500 100644
|
||||
--- a/src/platformsupport/fontdatabases/mac/qcoretextfontdatabase.mm
|
||||
+++ b/src/platformsupport/fontdatabases/mac/qcoretextfontdatabase.mm
|
||||
@@ -256,6 +256,13 @@ static void getFontDescription(CTFontDescriptorRef font, FontDescription *fd)
|
||||
|
||||
fd->foundryName = QStringLiteral("CoreText");
|
||||
fd->familyName = (CFStringRef) CTFontDescriptorCopyAttribute(font, kCTFontFamilyNameAttribute);
|
||||
+
|
||||
+ // Patch: Fix open sans semibold loading.
|
||||
+ QCFString _displayName = (CFStringRef) CTFontDescriptorCopyAttribute(font, kCTFontDisplayNameAttribute);
|
||||
+ if (_displayName == QStringLiteral("Open Sans Semibold")) {
|
||||
+ fd->familyName = _displayName;
|
||||
+ }
|
||||
+
|
||||
fd->styleName = (CFStringRef)CTFontDescriptorCopyAttribute(font, kCTFontStyleNameAttribute);
|
||||
fd->weight = QFont::Normal;
|
||||
fd->style = QFont::StyleNormal;
|
||||
diff --git a/src/plugins/platforms/cocoa/qcocoaapplicationdelegate.mm b/src/plugins/platforms/cocoa/qcocoaapplicationdelegate.mm
|
||||
index 92358ec..694fee7 100644
|
||||
--- a/src/plugins/platforms/cocoa/qcocoaapplicationdelegate.mm
|
||||
+++ b/src/plugins/platforms/cocoa/qcocoaapplicationdelegate.mm
|
||||
@@ -213,7 +213,8 @@ static void cleanupCocoaApplicationDelegate()
|
||||
if (reflectionDelegate) {
|
||||
if ([reflectionDelegate respondsToSelector:@selector(applicationShouldTerminate:)])
|
||||
return [reflectionDelegate applicationShouldTerminate:sender];
|
||||
- return NSTerminateNow;
|
||||
+ // Patch: Don't terminate if reflectionDelegate does not respond to that selector, just use the default.
|
||||
+ //return NSTerminateNow;
|
||||
}
|
||||
|
||||
if ([self canQuit]) {
|
||||
@@ -289,6 +290,11 @@ static void cleanupCocoaApplicationDelegate()
|
||||
|
||||
- (void)applicationDidFinishLaunching:(NSNotification *)aNotification
|
||||
{
|
||||
+ // Patch: We need to receive this notification in the delegate as well.
|
||||
+ if (reflectionDelegate
|
||||
+ && [reflectionDelegate respondsToSelector:@selector(applicationDidFinishLaunching:)])
|
||||
+ [reflectionDelegate applicationDidFinishLaunching:aNotification];
|
||||
+
|
||||
Q_UNUSED(aNotification);
|
||||
inLaunch = false;
|
||||
// qt_release_apple_event_handler();
|
||||
@@ -411,7 +417,9 @@ static void cleanupCocoaApplicationDelegate()
|
||||
{
|
||||
Q_UNUSED(replyEvent);
|
||||
NSString *urlString = [[event paramDescriptorForKeyword:keyDirectObject] stringValue];
|
||||
- QWindowSystemInterface::handleFileOpenEvent(QUrl(QCFString::toQString(urlString)));
|
||||
+
|
||||
+ // Patch: Fix opening of an external url by a protocol handler.
|
||||
+ QWindowSystemInterface::handleFileOpenEvent(QUrl::fromNSURL([NSURL URLWithString:urlString]));
|
||||
}
|
||||
|
||||
- (void)appleEventQuit:(NSAppleEventDescriptor *)event withReplyEvent:(NSAppleEventDescriptor *)replyEvent
|
||||
diff --git a/src/plugins/platforms/cocoa/qcocoaintegration.mm b/src/plugins/platforms/cocoa/qcocoaintegration.mm
|
||||
index 9fd05a6..dea6072 100644
|
||||
--- a/src/plugins/platforms/cocoa/qcocoaintegration.mm
|
||||
+++ b/src/plugins/platforms/cocoa/qcocoaintegration.mm
|
||||
@@ -402,14 +402,24 @@ void QCocoaIntegration::updateScreens()
|
||||
}
|
||||
siblings << screen;
|
||||
}
|
||||
+
|
||||
+ // Patch: Backport crash fix from Qt 5.6.1.
|
||||
+ // Set virtual siblings list. All screens in mScreens are siblings, because we ignored the
|
||||
+ // mirrors. Note that some of the screens we update the siblings list for here may be deleted
|
||||
+ // below, but update anyway to keep the to-be-deleted screens out of the siblings list.
|
||||
+ foreach (QCocoaScreen* screen, mScreens)
|
||||
+ screen->setVirtualSiblings(siblings);
|
||||
+
|
||||
// Now the leftovers in remainingScreens are no longer current, so we can delete them.
|
||||
foreach (QCocoaScreen* screen, remainingScreens) {
|
||||
mScreens.removeOne(screen);
|
||||
delete screen;
|
||||
}
|
||||
+
|
||||
+ // Patch: Backport crash fix from Qt 5.6.1.
|
||||
// All screens in mScreens are siblings, because we ignored the mirrors.
|
||||
- foreach (QCocoaScreen* screen, mScreens)
|
||||
- screen->setVirtualSiblings(siblings);
|
||||
+ //foreach (QCocoaScreen* screen, mScreens)
|
||||
+ // screen->setVirtualSiblings(siblings);
|
||||
}
|
||||
|
||||
QCocoaScreen *QCocoaIntegration::screenAtIndex(int index)
|
||||
diff --git a/src/plugins/platforms/cocoa/qcocoakeymapper.mm b/src/plugins/platforms/cocoa/qcocoakeymapper.mm
|
||||
index e46eaff..c62db53 100644
|
||||
--- a/src/plugins/platforms/cocoa/qcocoakeymapper.mm
|
||||
+++ b/src/plugins/platforms/cocoa/qcocoakeymapper.mm
|
||||
@@ -382,6 +382,12 @@ bool QCocoaKeyMapper::updateKeyboard()
|
||||
keyboardInputLocale = QLocale::c();
|
||||
keyboardInputDirection = Qt::LeftToRight;
|
||||
}
|
||||
+
|
||||
+ // Patch: Backport a fix for layout-independent keyboard shortcuts.
|
||||
+ const auto newMode = keyboard_mode;
|
||||
+ deleteLayouts();
|
||||
+ keyboard_mode = newMode;
|
||||
+
|
||||
return true;
|
||||
}
|
||||
|
||||
@@ -464,7 +470,8 @@ QList<int> QCocoaKeyMapper::possibleKeys(const QKeyEvent *event) const
|
||||
Qt::KeyboardModifiers neededMods = ModsTbl[i];
|
||||
int key = kbItem->qtKey[i];
|
||||
if (key && key != baseKey && ((keyMods & neededMods) == neededMods)) {
|
||||
- ret << int(key + (keyMods & ~neededMods));
|
||||
+ // Patch: Backport a fix for layout-independent keyboard shortcuts.
|
||||
+ ret << int(key + neededMods);
|
||||
}
|
||||
}
|
||||
return ret;
|
||||
diff --git a/src/plugins/platforms/cocoa/qcocoasystemtrayicon.mm b/src/plugins/platforms/cocoa/qcocoasystemtrayicon.mm
|
||||
index 83c960d..3b9f8d4 100755
|
||||
--- a/src/plugins/platforms/cocoa/qcocoasystemtrayicon.mm
|
||||
+++ b/src/plugins/platforms/cocoa/qcocoasystemtrayicon.mm
|
||||
@@ -102,7 +102,10 @@ QT_USE_NAMESPACE
|
||||
QCocoaSystemTrayIcon *systray;
|
||||
NSStatusItem *item;
|
||||
QCocoaMenu *menu;
|
||||
- bool menuVisible;
|
||||
+
|
||||
+ // Patch: Nice macOS tray icon support.
|
||||
+ bool menuVisible, iconSelected;
|
||||
+
|
||||
QIcon icon;
|
||||
QT_MANGLE_NAMESPACE(QNSImageView) *imageCell;
|
||||
}
|
||||
@@ -124,6 +127,10 @@ QT_USE_NAMESPACE
|
||||
QT_MANGLE_NAMESPACE(QNSStatusItem) *parent;
|
||||
}
|
||||
-(id)initWithParent:(QT_MANGLE_NAMESPACE(QNSStatusItem)*)myParent;
|
||||
+
|
||||
+// Patch: Nice macOS tray icon support.
|
||||
+-(void)updateIconSelection;
|
||||
+
|
||||
-(void)menuTrackingDone:(NSNotification*)notification;
|
||||
-(void)mousePressed:(NSEvent *)mouseEvent button:(Qt::MouseButton)mouseButton;
|
||||
@end
|
||||
@@ -187,6 +194,19 @@ void QCocoaSystemTrayIcon::cleanup()
|
||||
m_sys = 0;
|
||||
}
|
||||
|
||||
+// Patch: Nice macOS tray icon support.
|
||||
+namespace {
|
||||
+
|
||||
+qreal getDevicePixelRatio() {
|
||||
+ qreal result = 1.0;
|
||||
+ foreach (QScreen *screen, QGuiApplication::screens()) {
|
||||
+ result = qMax(result, screen->devicePixelRatio());
|
||||
+ }
|
||||
+ return result;
|
||||
+}
|
||||
+
|
||||
+} // namespace
|
||||
+
|
||||
void QCocoaSystemTrayIcon::updateIcon(const QIcon &icon)
|
||||
{
|
||||
if (!m_sys)
|
||||
@@ -194,13 +214,17 @@ void QCocoaSystemTrayIcon::updateIcon(const QIcon &icon)
|
||||
|
||||
m_sys->item->icon = icon;
|
||||
|
||||
- const bool menuVisible = m_sys->item->menu && m_sys->item->menuVisible;
|
||||
+ // Patch: Nice macOS tray icon support.
|
||||
+ //const bool menuVisible = m_sys->item->menu && m_sys->item->menuVisible;
|
||||
|
||||
CGFloat hgt = [[[NSApplication sharedApplication] mainMenu] menuBarHeight];
|
||||
- const short scale = hgt - 4;
|
||||
+
|
||||
+ // Patch: Nice macOS tray icon support.
|
||||
+ const short scale = hgt * getDevicePixelRatio();
|
||||
|
||||
QPixmap pm = m_sys->item->icon.pixmap(QSize(scale, scale),
|
||||
- menuVisible ? QIcon::Selected : QIcon::Normal);
|
||||
+ // Patch: Nice macOS tray icon support.
|
||||
+ m_sys->item->iconSelected ? QIcon::Selected : QIcon::Normal);
|
||||
if (pm.isNull()) {
|
||||
pm = QPixmap(scale, scale);
|
||||
pm.fill(Qt::transparent);
|
||||
@@ -322,15 +346,13 @@ QT_END_NAMESPACE
|
||||
return self;
|
||||
}
|
||||
|
||||
--(void)menuTrackingDone:(NSNotification*)notification
|
||||
+// Patch: Nice macOS tray icon support.
|
||||
+-(void)updateIconSelection
|
||||
{
|
||||
- Q_UNUSED(notification);
|
||||
- down = NO;
|
||||
-
|
||||
CGFloat hgt = [[[NSApplication sharedApplication] mainMenu] menuBarHeight];
|
||||
- const short scale = hgt - 4;
|
||||
-
|
||||
- QPixmap pm = parent->icon.pixmap(QSize(scale, scale), QIcon::Normal);
|
||||
+ const short scale = hgt * getDevicePixelRatio();
|
||||
+ QPixmap pm = parent->icon.pixmap(QSize(scale, scale),
|
||||
+ parent->iconSelected ? QIcon::Selected : QIcon::Normal);
|
||||
if (pm.isNull()) {
|
||||
pm = QPixmap(scale, scale);
|
||||
pm.fill(Qt::transparent);
|
||||
@@ -338,9 +360,19 @@ QT_END_NAMESPACE
|
||||
NSImage *nsaltimage = static_cast<NSImage *>(qt_mac_create_nsimage(pm));
|
||||
[self setImage: nsaltimage];
|
||||
[nsaltimage release];
|
||||
+}
|
||||
+
|
||||
+-(void)menuTrackingDone:(NSNotification*)notification
|
||||
+{
|
||||
+ Q_UNUSED(notification);
|
||||
+ down = NO;
|
||||
|
||||
parent->menuVisible = false;
|
||||
|
||||
+ // Patch: Nice macOS tray icon support.
|
||||
+ parent->iconSelected = false;
|
||||
+ [self updateIconSelection];
|
||||
+
|
||||
[self setNeedsDisplay:YES];
|
||||
}
|
||||
|
||||
@@ -350,18 +382,9 @@ QT_END_NAMESPACE
|
||||
int clickCount = [mouseEvent clickCount];
|
||||
[self setNeedsDisplay:YES];
|
||||
|
||||
- CGFloat hgt = [[[NSApplication sharedApplication] mainMenu] menuBarHeight];
|
||||
- const short scale = hgt - 4;
|
||||
-
|
||||
- QPixmap pm = parent->icon.pixmap(QSize(scale, scale),
|
||||
- parent->menuVisible ? QIcon::Selected : QIcon::Normal);
|
||||
- if (pm.isNull()) {
|
||||
- pm = QPixmap(scale, scale);
|
||||
- pm.fill(Qt::transparent);
|
||||
- }
|
||||
- NSImage *nsaltimage = static_cast<NSImage *>(qt_mac_create_nsimage(pm));
|
||||
- [self setImage: nsaltimage];
|
||||
- [nsaltimage release];
|
||||
+ // Patch: Nice macOS tray icon support.
|
||||
+ parent->iconSelected = (clickCount != 2) && parent->menu;
|
||||
+ [self updateIconSelection];
|
||||
|
||||
if (clickCount == 2) {
|
||||
[self menuTrackingDone:nil];
|
||||
@@ -380,6 +403,10 @@ QT_END_NAMESPACE
|
||||
{
|
||||
Q_UNUSED(mouseEvent);
|
||||
[self menuTrackingDone:nil];
|
||||
+
|
||||
+ // Patch: Nice macOS tray icon support.
|
||||
+ parent->iconSelected = false;
|
||||
+ [self updateIconSelection];
|
||||
}
|
||||
|
||||
- (void)rightMouseDown:(NSEvent *)mouseEvent
|
||||
@@ -391,6 +418,10 @@ QT_END_NAMESPACE
|
||||
{
|
||||
Q_UNUSED(mouseEvent);
|
||||
[self menuTrackingDone:nil];
|
||||
+
|
||||
+ // Patch: Nice macOS tray icon support.
|
||||
+ parent->iconSelected = false;
|
||||
+ [self updateIconSelection];
|
||||
}
|
||||
|
||||
- (void)otherMouseDown:(NSEvent *)mouseEvent
|
||||
@@ -405,7 +436,8 @@ QT_END_NAMESPACE
|
||||
}
|
||||
|
||||
-(void)drawRect:(NSRect)rect {
|
||||
- [[parent item] drawStatusBarBackgroundInRect:rect withHighlight:down];
|
||||
+ // Patch: Nice macOS tray icon support.
|
||||
+ [[parent item] drawStatusBarBackgroundInRect:rect withHighlight:parent->menu ? down : NO];
|
||||
[super drawRect:rect];
|
||||
}
|
||||
@end
|
||||
diff --git a/src/plugins/platforms/cocoa/qcocoawindow.mm b/src/plugins/platforms/cocoa/qcocoawindow.mm
|
||||
index 4d0458a..fde238a 100644
|
||||
--- a/src/plugins/platforms/cocoa/qcocoawindow.mm
|
||||
+++ b/src/plugins/platforms/cocoa/qcocoawindow.mm
|
||||
@@ -167,7 +167,8 @@ static bool isMouseEvent(NSEvent *ev)
|
||||
if (!self.window.delegate)
|
||||
return; // Already detached, pending NSAppKitDefined event
|
||||
|
||||
- if (pw && pw->frameStrutEventsEnabled() && isMouseEvent(theEvent)) {
|
||||
+ // Patch: Fix events loss if the window was minimized or hidden.
|
||||
+ if (pw && pw->frameStrutEventsEnabled() && pw->m_synchedWindowState != Qt::WindowMinimized && pw->m_isExposed && isMouseEvent(theEvent)) {
|
||||
NSPoint loc = [theEvent locationInWindow];
|
||||
NSRect windowFrame = [self.window legacyConvertRectFromScreen:[self.window frame]];
|
||||
NSRect contentFrame = [[self.window contentView] frame];
|
||||
@@ -914,6 +915,19 @@ void QCocoaWindow::setWindowFilePath(const QString &filePath)
|
||||
[m_nsWindow setRepresentedFilename: fi.exists() ? QCFString::toNSString(filePath) : @""];
|
||||
}
|
||||
|
||||
+// Patch: Nice macOS window icon.
|
||||
+namespace {
|
||||
+
|
||||
+qreal getDevicePixelRatio() {
|
||||
+ qreal result = 1.0;
|
||||
+ foreach (QScreen *screen, QGuiApplication::screens()) {
|
||||
+ result = qMax(result, screen->devicePixelRatio());
|
||||
+ }
|
||||
+ return result;
|
||||
+}
|
||||
+
|
||||
+} // namespace
|
||||
+
|
||||
void QCocoaWindow::setWindowIcon(const QIcon &icon)
|
||||
{
|
||||
QCocoaAutoReleasePool pool;
|
||||
@@ -929,7 +943,10 @@ void QCocoaWindow::setWindowIcon(const QIcon &icon)
|
||||
if (icon.isNull()) {
|
||||
[iconButton setImage:nil];
|
||||
} else {
|
||||
- QPixmap pixmap = icon.pixmap(QSize(22, 22));
|
||||
+ // Patch: Nice macOS window icon.
|
||||
+ CGFloat hgt = 16. * getDevicePixelRatio();
|
||||
+ QPixmap pixmap = icon.pixmap(QSize(hgt, hgt));
|
||||
+
|
||||
NSImage *image = static_cast<NSImage *>(qt_mac_create_nsimage(pixmap));
|
||||
[iconButton setImage:image];
|
||||
[image release];
|
||||
diff --git a/src/plugins/platforms/cocoa/qnsview.mm b/src/plugins/platforms/cocoa/qnsview.mm
|
||||
index a18ee7f..1f91feb 100644
|
||||
--- a/src/plugins/platforms/cocoa/qnsview.mm
|
||||
+++ b/src/plugins/platforms/cocoa/qnsview.mm
|
||||
@@ -393,7 +393,9 @@ static NSString *_q_NSWindowDidChangeOcclusionStateNotification = nil;
|
||||
[self notifyWindowStateChanged:newState];
|
||||
// NSWindowDidOrderOnScreenAndFinishAnimatingNotification is private API, and not
|
||||
// emitted in 10.6, so we bring back the old behavior for that case alone.
|
||||
- if (newState == Qt::WindowNoState && QSysInfo::QSysInfo::MacintoshVersion == QSysInfo::MV_10_6)
|
||||
+
|
||||
+ // Patch: Fix macOS window show after window was hidden.
|
||||
+ if (newState == Qt::WindowNoState/* && QSysInfo::QSysInfo::MacintoshVersion == QSysInfo::MV_10_6*/)
|
||||
m_platformWindow->exposeWindow();
|
||||
} else if ([notificationName isEqualToString: @"NSWindowDidOrderOffScreenNotification"]) {
|
||||
m_platformWindow->obscureWindow();
|
||||
@@ -1300,7 +1302,9 @@ static QTabletEvent::TabletDevice wacomTabletDevice(NSEvent *theEvent)
|
||||
#if MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_8
|
||||
if (QSysInfo::QSysInfo::MacintoshVersion >= QSysInfo::MV_10_8) {
|
||||
// On 10.8 and above, MayBegin is likely to happen. We treat it the same as an actual begin.
|
||||
- if (phase == NSEventPhaseMayBegin)
|
||||
+
|
||||
+ // Patch: Actual begin should be treated as begin as well.
|
||||
+ if (phase == NSEventPhaseMayBegin || phase == NSEventPhaseBegan)
|
||||
ph = Qt::ScrollBegin;
|
||||
} else
|
||||
#endif
|
||||
@@ -1366,14 +1370,22 @@ static QTabletEvent::TabletDevice wacomTabletDevice(NSEvent *theEvent)
|
||||
quint32 nativeVirtualKey = [nsevent keyCode];
|
||||
|
||||
QChar ch = QChar::ReplacementCharacter;
|
||||
- int keyCode = Qt::Key_unknown;
|
||||
- if ([characters length] != 0) {
|
||||
- if (((modifiers & Qt::MetaModifier) || (modifiers & Qt::AltModifier)) && ([charactersIgnoringModifiers length] != 0))
|
||||
- ch = QChar([charactersIgnoringModifiers characterAtIndex:0]);
|
||||
- else
|
||||
- ch = QChar([characters characterAtIndex:0]);
|
||||
- keyCode = [self convertKeyCode:ch];
|
||||
- }
|
||||
+
|
||||
+ // Patch: Backport a fix for layout-independent shortcuts.
|
||||
+ if ([characters length] != 0) // https://bugreports.qt.io/browse/QTBUG-42584
|
||||
+ ch = QChar([characters characterAtIndex:0]);
|
||||
+ else if ([charactersIgnoringModifiers length] != 0 && ((modifiers & Qt::MetaModifier) || (modifiers & Qt::AltModifier)))
|
||||
+ ch = QChar([charactersIgnoringModifiers characterAtIndex:0]);
|
||||
+
|
||||
+ int keyCode = [self convertKeyCode:ch];
|
||||
+ //int keyCode = Qt::Key_unknown;
|
||||
+ //if ([characters length] != 0) {
|
||||
+ // if (((modifiers & Qt::MetaModifier) || (modifiers & Qt::AltModifier)) && ([charactersIgnoringModifiers length] != 0))
|
||||
+ // ch = QChar([charactersIgnoringModifiers characterAtIndex:0]);
|
||||
+ // else
|
||||
+ // ch = QChar([characters characterAtIndex:0]);
|
||||
+ // keyCode = [self convertKeyCode:ch];
|
||||
+ //}
|
||||
|
||||
// we will send a key event unless the input method sets m_sendKeyEvent to false
|
||||
m_sendKeyEvent = true;
|
||||
@@ -1437,6 +1449,11 @@ static QTabletEvent::TabletDevice wacomTabletDevice(NSEvent *theEvent)
|
||||
&& qtKey == Qt::Key_Period) {
|
||||
[self handleKeyEvent:nsevent eventType:int(QEvent::KeyPress)];
|
||||
return YES;
|
||||
+
|
||||
+ // Patch: Allow us to handle Ctrl+Tab and Ctrl+Backtab in the app.
|
||||
+ } else if ([nsevent modifierFlags] & NSControlKeyMask && (qtKey == Qt::Key_Tab || qtKey == Qt::Key_Backtab)) {
|
||||
+ [self handleKeyEvent:nsevent eventType:int(QEvent::KeyPress)];
|
||||
+ return YES;
|
||||
}
|
||||
}
|
||||
return [super performKeyEquivalent:nsevent];
|
||||
diff --git a/src/tools/qlalr/lalr.cpp b/src/tools/qlalr/lalr.cpp
|
||||
index c680764..e2a7aaf 100644
|
||||
--- a/src/tools/qlalr/lalr.cpp
|
||||
+++ b/src/tools/qlalr/lalr.cpp
|
||||
@@ -246,11 +246,13 @@ void Grammar::buildExtendedGrammar ()
|
||||
non_terminals.insert (accept_symbol);
|
||||
}
|
||||
|
||||
-struct _Nullable: public std::unary_function<Name, bool>
|
||||
+// Patch: Fix building with the new SDK.
|
||||
+struct __Nullable: public std::unary_function<Name, bool>
|
||||
{
|
||||
Automaton *_M_automaton;
|
||||
|
||||
- _Nullable (Automaton *aut):
|
||||
+ // Patch: Fix building with the new SDK.
|
||||
+ __Nullable (Automaton *aut):
|
||||
_M_automaton (aut) {}
|
||||
|
||||
bool operator () (Name name) const
|
||||
@@ -308,7 +310,8 @@ void Automaton::buildNullables ()
|
||||
|
||||
for (RulePointer rule = _M_grammar->rules.begin (); rule != _M_grammar->rules.end (); ++rule)
|
||||
{
|
||||
- NameList::iterator nn = std::find_if (rule->rhs.begin (), rule->rhs.end (), std::not1 (_Nullable (this)));
|
||||
+ // Patch: Fix building with the new SDK.
|
||||
+ NameList::iterator nn = std::find_if (rule->rhs.begin (), rule->rhs.end (), std::not1 (__Nullable (this)));
|
||||
|
||||
if (nn == rule->rhs.end ())
|
||||
changed |= nullables.insert (rule->lhs).second;
|
||||
@@ -643,7 +646,8 @@ void Automaton::buildIncludesDigraph ()
|
||||
if (! _M_grammar->isNonTerminal (*A))
|
||||
continue;
|
||||
|
||||
- NameList::iterator first_not_nullable = std::find_if (dot, rule->rhs.end (), std::not1 (_Nullable (this)));
|
||||
+ // Patch: Fix building with the new SDK.
|
||||
+ NameList::iterator first_not_nullable = std::find_if (dot, rule->rhs.end (), std::not1 (__Nullable (this)));
|
||||
if (first_not_nullable != rule->rhs.end ())
|
||||
continue;
|
||||
|
||||
diff --git a/src/widgets/kernel/qwidget.cpp b/src/widgets/kernel/qwidget.cpp
|
||||
index 7396808..7178aec 100644
|
||||
--- a/src/widgets/kernel/qwidget.cpp
|
||||
+++ b/src/widgets/kernel/qwidget.cpp
|
||||
@@ -4722,6 +4722,17 @@ void QWidget::render(QPainter *painter, const QPoint &targetOffset,
|
||||
return; // Fully transparent.
|
||||
|
||||
Q_D(QWidget);
|
||||
+
|
||||
+ // Patch: save and restore dirtyOpaqueChildren field.
|
||||
+ //
|
||||
+ // Just like in QWidget::grab() this field should be restored
|
||||
+ // after the d->render() call, because it will be set to 1 and
|
||||
+ // opaqueChildren field will be filled with empty region in
|
||||
+ // case the widget is hidden (because all the opaque children
|
||||
+ // will be skipped in isVisible() check).
|
||||
+ //
|
||||
+ const bool oldDirtyOpaqueChildren = d->dirtyOpaqueChildren;
|
||||
+
|
||||
const bool inRenderWithPainter = d->extra && d->extra->inRenderWithPainter;
|
||||
const QRegion toBePainted = !inRenderWithPainter ? d->prepareToRender(sourceRegion, renderFlags)
|
||||
: sourceRegion;
|
||||
@@ -4743,6 +4754,10 @@ void QWidget::render(QPainter *painter, const QPoint &targetOffset,
|
||||
if (!inRenderWithPainter && (opacity < 1.0 || (target->devType() == QInternal::Printer))) {
|
||||
d->render_helper(painter, targetOffset, toBePainted, renderFlags);
|
||||
d->extra->inRenderWithPainter = inRenderWithPainter;
|
||||
+
|
||||
+ // Patch: save and restore dirtyOpaqueChildren field.
|
||||
+ d->dirtyOpaqueChildren = oldDirtyOpaqueChildren;
|
||||
+
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -4774,6 +4789,9 @@ void QWidget::render(QPainter *painter, const QPoint &targetOffset,
|
||||
d->setSharedPainter(oldPainter);
|
||||
|
||||
d->extra->inRenderWithPainter = inRenderWithPainter;
|
||||
+
|
||||
+ // Patch: save and restore dirtyOpaqueChildren field.
|
||||
+ d->dirtyOpaqueChildren = oldDirtyOpaqueChildren;
|
||||
}
|
||||
|
||||
static void sendResizeEvents(QWidget *target)
|
||||
@@ -7983,7 +8001,8 @@ bool QWidget::event(QEvent *event)
|
||||
case QEvent::KeyPress: {
|
||||
QKeyEvent *k = (QKeyEvent *)event;
|
||||
bool res = false;
|
||||
- if (!(k->modifiers() & (Qt::ControlModifier | Qt::AltModifier))) { //### Add MetaModifier?
|
||||
+ // Patch: Allow us to handle Ctrl+Tab and Ctrl+Backtab in the app.
|
||||
+ if (!(k->modifiers() & (Qt::ControlModifier | Qt::AltModifier | Qt::MetaModifier))) { //### Add MetaModifier?
|
||||
if (k->key() == Qt::Key_Backtab
|
||||
|| (k->key() == Qt::Key_Tab && (k->modifiers() & Qt::ShiftModifier)))
|
||||
res = focusNextPrevChild(false);
|
||||
diff --git a/src/widgets/styles/qmacstyle_mac.mm b/src/widgets/styles/qmacstyle_mac.mm
|
||||
index 0845a5e..5735cb6 100644
|
||||
--- a/src/widgets/styles/qmacstyle_mac.mm
|
||||
+++ b/src/widgets/styles/qmacstyle_mac.mm
|
||||
@@ -3667,9 +3667,11 @@ void QMacStyle::drawControl(ControlElement ce, const QStyleOption *opt, QPainter
|
||||
|
||||
NSBezierPath *pushButtonFocusRingPath;
|
||||
if (bdi.kind == kThemeBevelButton)
|
||||
- pushButtonFocusRingPath = [NSBezierPath bezierPathWithRect:focusRect];
|
||||
+ // Patch: Fix building with the new SDK.
|
||||
+ pushButtonFocusRingPath = [NSBezierPath bezierPathWithRect:NSRectFromCGRect(focusRect)];
|
||||
else
|
||||
- pushButtonFocusRingPath = [NSBezierPath bezierPathWithRoundedRect:focusRect xRadius:4 yRadius:4];
|
||||
+ // Patch: Fix building with the new SDK.
|
||||
+ pushButtonFocusRingPath = [NSBezierPath bezierPathWithRoundedRect:NSRectFromCGRect(focusRect) xRadius:4 yRadius:4];
|
||||
qt_drawFocusRingOnPath(cg, pushButtonFocusRingPath);
|
||||
}
|
||||
|
||||
diff --git a/src/widgets/util/qsystemtrayicon_qpa.cpp b/src/widgets/util/qsystemtrayicon_qpa.cpp
|
||||
index f98aeaf..00c0734 100644
|
||||
--- a/src/widgets/util/qsystemtrayicon_qpa.cpp
|
||||
+++ b/src/widgets/util/qsystemtrayicon_qpa.cpp
|
||||
@@ -99,13 +99,18 @@ void QSystemTrayIconPrivate::updateIcon_sys()
|
||||
|
||||
void QSystemTrayIconPrivate::updateMenu_sys()
|
||||
{
|
||||
- if (qpa_sys && menu) {
|
||||
- if (!menu->platformMenu()) {
|
||||
- QPlatformMenu *platformMenu = qpa_sys->createMenu();
|
||||
- if (platformMenu)
|
||||
- menu->setPlatformMenu(platformMenu);
|
||||
+ // Patch: Nice macOS tray icon support.
|
||||
+ if (qpa_sys) {
|
||||
+ if (menu) {
|
||||
+ if (!menu->platformMenu()) {
|
||||
+ QPlatformMenu *platformMenu = qpa_sys->createMenu();
|
||||
+ if (platformMenu)
|
||||
+ menu->setPlatformMenu(platformMenu);
|
||||
+ }
|
||||
+ qpa_sys->updateMenu(menu->platformMenu());
|
||||
+ } else {
|
||||
+ qpa_sys->updateMenu(0);
|
||||
}
|
||||
- qpa_sys->updateMenu(menu->platformMenu());
|
||||
}
|
||||
}
|
||||
|
||||
diff --git a/src/widgets/widgets/qwidgetlinecontrol.cpp b/src/widgets/widgets/qwidgetlinecontrol.cpp
|
||||
index 75f3059..980f2be 100644
|
||||
--- a/src/widgets/widgets/qwidgetlinecontrol.cpp
|
||||
+++ b/src/widgets/widgets/qwidgetlinecontrol.cpp
|
||||
@@ -1867,7 +1867,8 @@ void QWidgetLineControl::processKeyEvent(QKeyEvent* event)
|
||||
|
||||
if (unknown && !isReadOnly()) {
|
||||
QString t = event->text();
|
||||
- if (!t.isEmpty() && t.at(0).isPrint()) {
|
||||
+ // Patch: Enable ZWJ and ZWNJ characters to be in text input.
|
||||
+ if (!t.isEmpty() && (t.at(0).isPrint() || t.at(0).unicode() == 0x200C || t.at(0).unicode() == 0x200D)) {
|
||||
insert(t);
|
||||
#ifndef QT_NO_COMPLETER
|
||||
complete(event->key());
|
||||
diff --git a/src/widgets/widgets/qwidgettextcontrol.cpp b/src/widgets/widgets/qwidgettextcontrol.cpp
|
||||
index 96438a0..b0b7206 100644
|
||||
--- a/src/widgets/widgets/qwidgettextcontrol.cpp
|
||||
+++ b/src/widgets/widgets/qwidgettextcontrol.cpp
|
||||
@@ -1342,7 +1342,8 @@ void QWidgetTextControlPrivate::keyPressEvent(QKeyEvent *e)
|
||||
process:
|
||||
{
|
||||
QString text = e->text();
|
||||
- if (!text.isEmpty() && (text.at(0).isPrint() || text.at(0) == QLatin1Char('\t'))) {
|
||||
+ // Patch: Enable ZWJ and ZWNJ characters to be in text input.
|
||||
+ if (!text.isEmpty() && (text.at(0).isPrint() || text.at(0) == QLatin1Char('\t') || text.at(0).unicode() == 0x200C || text.at(0).unicode() == 0x200D)) {
|
||||
if (overwriteMode
|
||||
// no need to call deleteChar() if we have a selection, insertText
|
||||
// does it already
|
||||
@@ -1,3 +1,17 @@
|
||||
diff --git a/configure b/configure
|
||||
index 7651e29..11e6f90 100755
|
||||
--- a/configure
|
||||
+++ b/configure
|
||||
@@ -527,7 +527,8 @@ if [ "$BUILD_ON_MAC" = "yes" ]; then
|
||||
exit 2
|
||||
fi
|
||||
|
||||
- if ! /usr/bin/xcrun -find xcrun >/dev/null 2>&1; then
|
||||
+ # Patch: Fix Qt for working with Xcode 8.
|
||||
+ if ! /usr/bin/xcrun -find xcodebuild >/dev/null 2>&1; then
|
||||
echo >&2
|
||||
echo " Xcode not set up properly. You may need to confirm the license" >&2
|
||||
echo " agreement by running /usr/bin/xcodebuild without arguments." >&2
|
||||
diff --git a/mkspecs/common/msvc-desktop.conf b/mkspecs/common/msvc-desktop.conf
|
||||
index eec9e1f..ec3015e 100644
|
||||
--- a/mkspecs/common/msvc-desktop.conf
|
||||
@@ -16,6 +30,21 @@ index eec9e1f..ec3015e 100644
|
||||
QMAKE_CFLAGS_YACC =
|
||||
QMAKE_CFLAGS_LTCG = -GL
|
||||
QMAKE_CFLAGS_SSE2 = -arch:SSE2
|
||||
diff --git a/mkspecs/features/mac/default_pre.prf b/mkspecs/features/mac/default_pre.prf
|
||||
index 0cc8cd6..ca9725b 100644
|
||||
--- a/mkspecs/features/mac/default_pre.prf
|
||||
+++ b/mkspecs/features/mac/default_pre.prf
|
||||
@@ -12,7 +12,9 @@ isEmpty(QMAKE_XCODE_DEVELOPER_PATH) {
|
||||
error("Xcode is not installed in $${QMAKE_XCODE_DEVELOPER_PATH}. Please use xcode-select to choose Xcode installation path.")
|
||||
|
||||
# Make sure Xcode is set up properly
|
||||
- isEmpty($$list($$system("/usr/bin/xcrun -find xcrun 2>/dev/null"))): \
|
||||
+
|
||||
+ # Patch: Fix Qt for working with Xcode 8.
|
||||
+ isEmpty($$list($$system("/usr/bin/xcrun -find xcodebuild 2>/dev/null"))): \
|
||||
error("Xcode not set up properly. You may need to confirm the license agreement by running /usr/bin/xcodebuild.")
|
||||
}
|
||||
|
||||
diff --git a/src/corelib/io/qfilesystemengine_win.cpp b/src/corelib/io/qfilesystemengine_win.cpp
|
||||
index f1a6019..81ff6ef 100644
|
||||
--- a/src/corelib/io/qfilesystemengine_win.cpp
|
||||
@@ -47,6 +76,20 @@ index 14e4fd1..c31c62b 100644
|
||||
{ 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 14, 9, 11, 11 },
|
||||
{ 3, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 14, 9, 11, 11 },
|
||||
{ 3, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 14, 9, 11, 11 },
|
||||
diff --git a/src/gui/kernel/qhighdpiscaling.cpp b/src/gui/kernel/qhighdpiscaling.cpp
|
||||
index b0ef2a2..7d5f7bc 100644
|
||||
--- a/src/gui/kernel/qhighdpiscaling.cpp
|
||||
+++ b/src/gui/kernel/qhighdpiscaling.cpp
|
||||
@@ -51,6 +51,9 @@ static const char screenFactorsEnvVar[] = "QT_SCREEN_SCALE_FACTORS";
|
||||
|
||||
static inline qreal initialGlobalScaleFactor()
|
||||
{
|
||||
+ // Disable environment variable dpi scaling changing.
|
||||
+ // It is not supported by Telegram Desktop :(
|
||||
+ return 1.;
|
||||
|
||||
qreal result = 1;
|
||||
if (qEnvironmentVariableIsSet(scaleFactorEnvVar)) {
|
||||
diff --git a/src/gui/kernel/qplatformdialoghelper.h b/src/gui/kernel/qplatformdialoghelper.h
|
||||
index 5b2f4ec..346a26f 100644
|
||||
--- a/src/gui/kernel/qplatformdialoghelper.h
|
||||
@@ -11236,7 +11279,7 @@ index faea54b..7d85080 100644
|
||||
|
||||
contains(QT_CONFIG, xcb-plugin): SUBDIRS += compose
|
||||
diff --git a/src/plugins/platforms/cocoa/qcocoaapplicationdelegate.mm b/src/plugins/platforms/cocoa/qcocoaapplicationdelegate.mm
|
||||
index caa8884..b083e65 100644
|
||||
index caa8884..72941e4 100644
|
||||
--- a/src/plugins/platforms/cocoa/qcocoaapplicationdelegate.mm
|
||||
+++ b/src/plugins/platforms/cocoa/qcocoaapplicationdelegate.mm
|
||||
@@ -210,7 +210,8 @@ QT_END_NAMESPACE
|
||||
@@ -11249,6 +11292,23 @@ index caa8884..b083e65 100644
|
||||
}
|
||||
|
||||
if ([self canQuit]) {
|
||||
@@ -287,11 +288,15 @@ QT_END_NAMESPACE
|
||||
|
||||
- (void)applicationDidFinishLaunching:(NSNotification *)aNotification
|
||||
{
|
||||
+ // We need to catch that notification in delegate.
|
||||
+ if (reflectionDelegate
|
||||
+ && [reflectionDelegate respondsToSelector:@selector(applicationDidFinishLaunching:)])
|
||||
+ [reflectionDelegate applicationDidFinishLaunching:aNotification];
|
||||
+
|
||||
Q_UNUSED(aNotification);
|
||||
inLaunch = false;
|
||||
// qt_release_apple_event_handler();
|
||||
|
||||
-
|
||||
// Insert code here to initialize your application
|
||||
}
|
||||
|
||||
diff --git a/src/plugins/platforms/cocoa/qcocoabackingstore.h b/src/plugins/platforms/cocoa/qcocoabackingstore.h
|
||||
index 5a199de..5622728 100644
|
||||
--- a/src/plugins/platforms/cocoa/qcocoabackingstore.h
|
||||
|
||||
47
Telegram/Patches/qtimageformats_5_3_2.diff
Normal file
@@ -0,0 +1,47 @@
|
||||
diff --git a/src/3rdparty/libwebp/src/dec/vp8l.c b/src/3rdparty/libwebp/src/dec/vp8l.c
|
||||
index ea0254d..953ff01 100644
|
||||
--- a/src/3rdparty/libwebp/src/dec/vp8l.c
|
||||
+++ b/src/3rdparty/libwebp/src/dec/vp8l.c
|
||||
@@ -12,7 +12,7 @@
|
||||
// Authors: Vikas Arora (vikaas.arora@gmail.com)
|
||||
// Jyrki Alakuijala (jyrki@google.com)
|
||||
|
||||
-#include <stdio.h>
|
||||
+// Patch: Backport of a crash fix.
|
||||
#include <stdlib.h>
|
||||
#include "./alphai.h"
|
||||
#include "./vp8li.h"
|
||||
@@ -740,6 +740,10 @@ static int DecodeAlphaData(VP8LDecoder* const dec, uint8_t* const data,
|
||||
const int len_code_limit = NUM_LITERAL_CODES + NUM_LENGTH_CODES;
|
||||
const int mask = hdr->huffman_mask_;
|
||||
assert(htree_group != NULL);
|
||||
+
|
||||
+ // Patch: Backport of a crash fix.
|
||||
+ assert(pos < end);
|
||||
+
|
||||
assert(last_row <= height);
|
||||
assert(Is8bOptimizable(hdr));
|
||||
|
||||
@@ -830,6 +834,10 @@ static int DecodeImageData(VP8LDecoder* const dec, uint32_t* const data,
|
||||
(hdr->color_cache_size_ > 0) ? &hdr->color_cache_ : NULL;
|
||||
const int mask = hdr->huffman_mask_;
|
||||
assert(htree_group != NULL);
|
||||
+
|
||||
+ // Patch: Backport of a crash fix.
|
||||
+ assert(src < src_end);
|
||||
+
|
||||
assert(src_last <= src_end);
|
||||
|
||||
while (!br->eos_ && src < src_last) {
|
||||
@@ -1294,6 +1302,11 @@ int VP8LDecodeAlphaImageStream(ALPHDecoder* const alph_dec, int last_row) {
|
||||
assert(dec->action_ == READ_DATA);
|
||||
assert(last_row <= dec->height_);
|
||||
|
||||
+ // Patch: Backport of a crash fix.
|
||||
+ if (dec->last_pixel_ == dec->width_ * dec->height_) {
|
||||
+ return 1; // done
|
||||
+ }
|
||||
+
|
||||
// Decode (with special row processing).
|
||||
return alph_dec->use_8b_decode ?
|
||||
DecodeAlphaData(dec, (uint8_t*)dec->pixels_, dec->width_, dec->height_,
|
||||
|
Before Width: | Height: | Size: 260 KiB After Width: | Height: | Size: 105 KiB |
|
Before Width: | Height: | Size: 197 KiB After Width: | Height: | Size: 197 KiB |
|
Before Width: | Height: | Size: 49 B |
|
Before Width: | Height: | Size: 1.9 KiB |
|
Before Width: | Height: | Size: 1.9 KiB |
|
Before Width: | Height: | Size: 1.8 KiB |
|
Before Width: | Height: | Size: 1.9 KiB |
|
Before Width: | Height: | Size: 2.0 KiB |
|
Before Width: | Height: | Size: 2.0 KiB |
|
Before Width: | Height: | Size: 1.9 KiB |
|
Before Width: | Height: | Size: 1.9 KiB |
|
Before Width: | Height: | Size: 1.3 KiB After Width: | Height: | Size: 5.3 KiB |
|
Before Width: | Height: | Size: 4.4 KiB After Width: | Height: | Size: 9.1 KiB |
|
Before Width: | Height: | Size: 22 KiB After Width: | Height: | Size: 35 KiB |
|
Before Width: | Height: | Size: 1.4 KiB After Width: | Height: | Size: 826 B |
|
Before Width: | Height: | Size: 15 KiB After Width: | Height: | Size: 17 KiB |
|
Before Width: | Height: | Size: 361 KiB After Width: | Height: | Size: 361 KiB |
|
Before Width: | Height: | Size: 8.3 KiB After Width: | Height: | Size: 21 KiB |
|
Before Width: | Height: | Size: 31 KiB After Width: | Height: | Size: 60 KiB |
|
Before Width: | Height: | Size: 1.8 KiB After Width: | Height: | Size: 1.9 KiB |
|
Before Width: | Height: | Size: 16 KiB After Width: | Height: | Size: 19 KiB |
|
Before Width: | Height: | Size: 2.3 KiB After Width: | Height: | Size: 3.0 KiB |
|
Before Width: | Height: | Size: 17 KiB After Width: | Height: | Size: 21 KiB |
|
Before Width: | Height: | Size: 17 KiB After Width: | Height: | Size: 46 KiB |
|
Before Width: | Height: | Size: 47 KiB After Width: | Height: | Size: 95 KiB |
|
Before Width: | Height: | Size: 2.7 KiB After Width: | Height: | Size: 4.1 KiB |
|
Before Width: | Height: | Size: 18 KiB After Width: | Height: | Size: 9.1 KiB |
|
Before Width: | Height: | Size: 34 KiB After Width: | Height: | Size: 84 KiB |
|
Before Width: | Height: | Size: 8.7 KiB After Width: | Height: | Size: 24 KiB |
|
Before Width: | Height: | Size: 36 KiB After Width: | Height: | Size: 24 KiB |
BIN
Telegram/Resources/art/mac_setup.tiff
Normal file
|
Before Width: | Height: | Size: 2.3 KiB |
|
Before Width: | Height: | Size: 176 KiB |
|
Before Width: | Height: | Size: 238 KiB |
BIN
Telegram/Resources/art/sunrise.jpg
Normal file
|
After Width: | Height: | Size: 117 KiB |
|
Before Width: | Height: | Size: 1.8 KiB |
|
Before Width: | Height: | Size: 1.8 KiB |
|
Before Width: | Height: | Size: 1.7 KiB |
|
Before Width: | Height: | Size: 1.7 KiB |
|
Before Width: | Height: | Size: 1.6 KiB |
|
Before Width: | Height: | Size: 1.8 KiB |
|
Before Width: | Height: | Size: 1.7 KiB |
|
Before Width: | Height: | Size: 1.7 KiB |
@@ -1,466 +0,0 @@
|
||||
/*
|
||||
This file is part of Telegram Desktop,
|
||||
the official desktop version of Telegram messaging app, see https://telegram.org
|
||||
|
||||
Telegram Desktop is free software: you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation, either version 3 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
It is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
In addition, as a special exception, the copyright holders give permission
|
||||
to link the code of portions of this program with the OpenSSL library.
|
||||
|
||||
Full license: https://github.com/telegramdesktop/tdesktop/blob/master/LICENSE
|
||||
Copyright (c) 2014-2016 John Preston, https://desktop.telegram.org
|
||||
*/
|
||||
|
||||
textStyle {
|
||||
linkFlags: font;
|
||||
linkFlagsOver: font;
|
||||
linkFg: color;
|
||||
linkFgDown: color;
|
||||
monoFg: color;
|
||||
selectBg: color;
|
||||
selectOverlay: color;
|
||||
lineHeight: pixels;
|
||||
}
|
||||
|
||||
linkButton {
|
||||
color: color;
|
||||
overColor: color;
|
||||
downColor: color;
|
||||
font: font;
|
||||
overFont: font;
|
||||
}
|
||||
|
||||
sysButton {
|
||||
size: size;
|
||||
img: sprite;
|
||||
color: color;
|
||||
overColor: color;
|
||||
duration: int;
|
||||
}
|
||||
|
||||
flatButton {
|
||||
color: color;
|
||||
overColor: color;
|
||||
downColor: color;
|
||||
|
||||
bgColor: color;
|
||||
overBgColor: color;
|
||||
downBgColor: color;
|
||||
|
||||
width: pixels;
|
||||
height: pixels;
|
||||
|
||||
textTop: pixels;
|
||||
overTextTop: pixels;
|
||||
downTextTop: pixels;
|
||||
|
||||
font: font;
|
||||
overFont: font;
|
||||
duration: int;
|
||||
cursor: cursor;
|
||||
|
||||
radius: pixels;
|
||||
}
|
||||
|
||||
iconedButton {
|
||||
icon: sprite;
|
||||
iconPos: point;
|
||||
downIcon: sprite;
|
||||
downIconPos: point;
|
||||
|
||||
color: color;
|
||||
bgColor: color;
|
||||
overBgColor: color;
|
||||
width: pixels;
|
||||
height: pixels;
|
||||
font: font;
|
||||
|
||||
opacity: double;
|
||||
overOpacity: double;
|
||||
|
||||
textPos: point;
|
||||
downTextPos: point;
|
||||
|
||||
duration: int;
|
||||
cursor: cursor;
|
||||
}
|
||||
|
||||
flatCheckbox {
|
||||
textColor: color;
|
||||
bgColor: color;
|
||||
disColor: color;
|
||||
|
||||
width: pixels;
|
||||
height: pixels;
|
||||
textTop: pixels;
|
||||
textLeft: pixels;
|
||||
font: font;
|
||||
duration: int;
|
||||
bgFunc: transition;
|
||||
cursor: cursor;
|
||||
|
||||
disabledCursor: cursor;
|
||||
|
||||
imageRect: sprite;
|
||||
chkImageRect: sprite;
|
||||
overImageRect: sprite;
|
||||
chkOverImageRect: sprite;
|
||||
disImageRect: sprite;
|
||||
chkDisImageRect: sprite;
|
||||
|
||||
imagePos: point;
|
||||
}
|
||||
|
||||
flatInput {
|
||||
textColor: color;
|
||||
bgColor: color;
|
||||
bgActive: color;
|
||||
width: pixels;
|
||||
height: pixels;
|
||||
textMrg: margins;
|
||||
align: align;
|
||||
font: font;
|
||||
cursor: cursor;
|
||||
|
||||
imgRect: sprite;
|
||||
imgPos: point;
|
||||
|
||||
borderWidth: pixels;
|
||||
borderColor: color;
|
||||
borderActive: color;
|
||||
borderError: color;
|
||||
|
||||
phColor: color;
|
||||
phFocusColor: color;
|
||||
phPos: point;
|
||||
phAlign: align;
|
||||
phShift: pixels;
|
||||
phDuration: int;
|
||||
phLeftFunc: transition;
|
||||
phAlphaFunc: transition;
|
||||
phColorFunc: transition;
|
||||
}
|
||||
|
||||
flatTextarea {
|
||||
textColor: color;
|
||||
bgColor: color;
|
||||
width: pixels;
|
||||
textMrg: margins;
|
||||
align: align;
|
||||
font: font;
|
||||
cursor: cursor;
|
||||
|
||||
phColor: color;
|
||||
phFocusColor: color;
|
||||
phPos: point;
|
||||
phAlign: align;
|
||||
phShift: pixels;
|
||||
phDuration: int;
|
||||
phLeftFunc: transition;
|
||||
phAlphaFunc: transition;
|
||||
phColorFunc: transition;
|
||||
}
|
||||
|
||||
flatScroll {
|
||||
barColor: color;
|
||||
bgColor: color;
|
||||
barOverColor: color;
|
||||
bgOverColor: color;
|
||||
|
||||
round: pixels;
|
||||
|
||||
width: pixels;
|
||||
minHeight: pixels;
|
||||
deltax: pixels;
|
||||
deltat: pixels;
|
||||
deltab: pixels;
|
||||
|
||||
topsh: pixels;
|
||||
bottomsh: pixels;
|
||||
shColor: color;
|
||||
|
||||
duration: int;
|
||||
hiding: int;
|
||||
}
|
||||
|
||||
countryInput {
|
||||
width: pixels;
|
||||
height: pixels;
|
||||
top: pixels;
|
||||
bgColor: color;
|
||||
ptrSize: size;
|
||||
textMrg: margins;
|
||||
font: font;
|
||||
align: align;
|
||||
}
|
||||
|
||||
slider {
|
||||
color: color;
|
||||
thickness: pixels;
|
||||
|
||||
width: pixels;
|
||||
bar: sprite;
|
||||
}
|
||||
|
||||
flatLabel {
|
||||
font: font;
|
||||
margin: margins;
|
||||
width: pixels;
|
||||
align: align;
|
||||
textFg: color;
|
||||
maxHeight: pixels;
|
||||
}
|
||||
|
||||
switcher {
|
||||
border: pixels;
|
||||
borderColor: color;
|
||||
|
||||
bgColor: color;
|
||||
bgHovered: color;
|
||||
bgActive: color;
|
||||
|
||||
height: pixels;
|
||||
|
||||
font: font;
|
||||
textColor: color;
|
||||
activeColor: color;
|
||||
|
||||
duration: int;
|
||||
}
|
||||
|
||||
dropdown {
|
||||
border: pixels;
|
||||
borderColor: color;
|
||||
|
||||
padding: margins;
|
||||
shadow: sprite;
|
||||
shadowShift: pixels;
|
||||
|
||||
duration: int;
|
||||
width: pixels;
|
||||
}
|
||||
|
||||
InnerDropdown {
|
||||
padding: margins;
|
||||
shadow: icon;
|
||||
shadowShift: pixels;
|
||||
|
||||
duration: int;
|
||||
width: pixels;
|
||||
|
||||
scrollMargin: margins;
|
||||
scrollPadding: margins;
|
||||
}
|
||||
|
||||
PopupMenu {
|
||||
skip: pixels;
|
||||
|
||||
shadow: sprite;
|
||||
shadowShift: pixels;
|
||||
|
||||
itemBg: color;
|
||||
itemBgOver: color;
|
||||
itemFg: color;
|
||||
itemFgOver: color;
|
||||
itemFgDisabled: color;
|
||||
itemFgShortcut: color;
|
||||
itemFgShortcutOver: color;
|
||||
itemFgShortcutDisabled: color;
|
||||
itemPadding: margins;
|
||||
itemFont: font;
|
||||
|
||||
separatorPadding: margins;
|
||||
separatorWidth: pixels;
|
||||
separatorFg: color;
|
||||
|
||||
arrow: sprite;
|
||||
|
||||
duration: int;
|
||||
|
||||
widthMin: pixels;
|
||||
widthMax: pixels;
|
||||
}
|
||||
|
||||
Tooltip {
|
||||
textBg: color;
|
||||
textFg: color;
|
||||
textFont: font;
|
||||
textBorder: color;
|
||||
textPadding: margins;
|
||||
|
||||
shift: point;
|
||||
skip: pixels;
|
||||
|
||||
widthMax: pixels;
|
||||
linesMax: int;
|
||||
}
|
||||
|
||||
botKeyboardButton {
|
||||
margin: pixels;
|
||||
padding: pixels;
|
||||
height: pixels;
|
||||
textTop: pixels;
|
||||
downTextTop: pixels;
|
||||
}
|
||||
|
||||
RoundButton {
|
||||
textFg: color;
|
||||
textFgOver: color;
|
||||
textBg: color; // rect of textBg with rounded rect of textBgOver upon it
|
||||
textBgOver: color;
|
||||
|
||||
secondaryTextFg: color;
|
||||
secondaryTextFgOver: color;
|
||||
secondarySkip: pixels;
|
||||
|
||||
width: pixels;
|
||||
height: pixels;
|
||||
padding: margins;
|
||||
|
||||
textTop: pixels;
|
||||
downTextTop: pixels;
|
||||
|
||||
icon: icon;
|
||||
|
||||
font: font;
|
||||
duration: int;
|
||||
}
|
||||
|
||||
Checkbox {
|
||||
textFg: color;
|
||||
textBg: color;
|
||||
|
||||
checkFg: color;
|
||||
checkFgOver: color;
|
||||
checkFgActive: color;
|
||||
|
||||
width: pixels;
|
||||
height: pixels;
|
||||
|
||||
textPosition: point;
|
||||
diameter: pixels;
|
||||
thickness: pixels;
|
||||
checkIcon: icon;
|
||||
|
||||
font: font;
|
||||
duration: int;
|
||||
}
|
||||
|
||||
Radiobutton {
|
||||
textFg: color;
|
||||
textBg: color;
|
||||
|
||||
checkFg: color;
|
||||
checkFgOver: color;
|
||||
checkFgActive: color;
|
||||
|
||||
width: pixels;
|
||||
height: pixels;
|
||||
|
||||
textPosition: point;
|
||||
diameter: pixels;
|
||||
thickness: pixels;
|
||||
checkSkip: pixels;
|
||||
|
||||
font: font;
|
||||
duration: int;
|
||||
}
|
||||
|
||||
InputArea {
|
||||
textFg: color;
|
||||
textMargins: margins;
|
||||
|
||||
placeholderFg: color;
|
||||
placeholderFgActive: color;
|
||||
placeholderMargins: margins;
|
||||
placeholderAlign: align;
|
||||
placeholderShift: pixels;
|
||||
|
||||
duration: int;
|
||||
|
||||
borderFg: color;
|
||||
borderFgActive: color;
|
||||
borderFgError: color;
|
||||
|
||||
border: pixels;
|
||||
borderActive: pixels;
|
||||
borderError: pixels;
|
||||
|
||||
font: font;
|
||||
|
||||
width: pixels;
|
||||
heightMin: pixels;
|
||||
heightMax: pixels;
|
||||
}
|
||||
|
||||
InputField {
|
||||
textFg: color;
|
||||
textMargins: margins;
|
||||
textAlign: align;
|
||||
|
||||
placeholderFg: color;
|
||||
placeholderFgActive: color;
|
||||
placeholderMargins: margins;
|
||||
placeholderAlign: align;
|
||||
placeholderShift: pixels;
|
||||
|
||||
duration: int;
|
||||
|
||||
borderFg: color;
|
||||
borderFgActive: color;
|
||||
borderFgError: color;
|
||||
|
||||
border: pixels;
|
||||
borderActive: pixels;
|
||||
borderError: pixels;
|
||||
|
||||
font: font;
|
||||
|
||||
width: pixels;
|
||||
height: pixels;
|
||||
|
||||
iconSprite: sprite;
|
||||
iconPosition: point;
|
||||
}
|
||||
|
||||
PeerAvatarButton {
|
||||
size: pixels;
|
||||
photoSize: pixels;
|
||||
}
|
||||
|
||||
OutlineButton {
|
||||
outlineWidth: pixels;
|
||||
outlineFg: color;
|
||||
outlineFgOver: color;
|
||||
|
||||
textBg: color;
|
||||
textBgOver: color;
|
||||
|
||||
textFg: color;
|
||||
textFgOver: color;
|
||||
|
||||
font: font;
|
||||
padding: margins;
|
||||
}
|
||||
|
||||
IconButton {
|
||||
width: pixels;
|
||||
height: pixels;
|
||||
|
||||
opacity: double;
|
||||
overOpacity: double;
|
||||
|
||||
icon: icon;
|
||||
iconPosition: point;
|
||||
downIconPosition: point;
|
||||
|
||||
duration: int;
|
||||
}
|
||||
455
Telegram/Resources/colors.palette
Normal file
@@ -0,0 +1,455 @@
|
||||
/*
|
||||
This file is part of Telegram Desktop,
|
||||
the official desktop version of Telegram messaging app, see https://telegram.org
|
||||
|
||||
Telegram Desktop is free software: you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation, either version 3 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
It is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
In addition, as a special exception, the copyright holders give permission
|
||||
to link the code of portions of this program with the OpenSSL library.
|
||||
|
||||
Full license: https://github.com/telegramdesktop/tdesktop/blob/master/LICENSE
|
||||
Copyright (c) 2014-2016 John Preston, https://desktop.telegram.org
|
||||
*/
|
||||
|
||||
// basic
|
||||
windowBg: #ffffff; // white: fallback for background
|
||||
windowFg: #000000; // black: fallback for text color
|
||||
windowBgOver: #f1f1f1; // light gray: fallback for over background
|
||||
windowBgRipple: #e5e5e5; // darker gray: fallback for ripple effect
|
||||
windowFgOver: windowFg; // black: fallback for over text color
|
||||
windowSubTextFg: #999999; // gray: fallback for subtext color
|
||||
windowSubTextFgOver: #919191; // gray over light blue: fallback for subtext over color
|
||||
windowBoldFg: #222222; // dark gray: fallback for bold text color
|
||||
windowBoldFgOver: #222222; // dark gray: fallback for over bold text color
|
||||
windowBgActive: #40a7e3; // bright blue: fallback for blue filled active areas
|
||||
windowFgActive: #ffffff; // text on bright blue: fallback for text on active areas
|
||||
windowActiveTextFg: #168acd; // online blue: fallback for active color
|
||||
windowShadowFg: #000000; // black: fallback for shadow color
|
||||
windowShadowFgFallback: #f1f1f1; // gray: fallback for shadow without opacity
|
||||
|
||||
shadowFg: #00000018;
|
||||
slideFadeOutBg: #0000003c;
|
||||
slideFadeOutShadowFg: windowShadowFg;
|
||||
|
||||
imageBg: #000000;
|
||||
imageBgTransparent: #ffffff;
|
||||
|
||||
// widgets
|
||||
activeButtonBg: windowBgActive;
|
||||
activeButtonBgOver: #39a5db;
|
||||
activeButtonBgRipple: #2095d0;
|
||||
activeButtonFg: windowFgActive;
|
||||
activeButtonFgOver: activeButtonFg;
|
||||
activeButtonSecondaryFg: #cceeff;
|
||||
activeButtonSecondaryFgOver: activeButtonSecondaryFg;
|
||||
activeLineFg: #37a1de;
|
||||
activeLineFgError: #e48383;
|
||||
|
||||
lightButtonBg: windowBg;
|
||||
lightButtonBgOver: #e3f1fa;
|
||||
lightButtonBgRipple: #c9e4f6;
|
||||
lightButtonFg: windowActiveTextFg;
|
||||
lightButtonFgOver: lightButtonFg;
|
||||
|
||||
attentionButtonFg: #d14e4e;
|
||||
attentionButtonFgOver: #d14e4e;
|
||||
attentionButtonBgOver: #fcdfde;
|
||||
attentionButtonBgRipple: #f4c3c2;
|
||||
|
||||
outlineButtonBg: windowBg;
|
||||
outlineButtonBgOver: lightButtonBgOver;
|
||||
outlineButtonOutlineFg: windowBgActive;
|
||||
outlineButtonBgRipple: lightButtonBgRipple;
|
||||
|
||||
menuBg: windowBg;
|
||||
menuBgOver: windowBgOver;
|
||||
menuBgRipple: windowBgRipple;
|
||||
menuIconFg: #a8a8a8;
|
||||
menuIconFgOver: #999999;
|
||||
menuSubmenuArrowFg: #373737;
|
||||
menuFgDisabled: #cccccc;
|
||||
menuSeparatorFg: #f1f1f1;
|
||||
|
||||
scrollBarBg: #00000053;
|
||||
scrollBarBgOver: #0000007a;
|
||||
scrollBg: #0000001a;
|
||||
scrollBgOver: #0000002c;
|
||||
|
||||
smallCloseIconFg: #c7c7c7;
|
||||
smallCloseIconFgOver: #a3a3a3;
|
||||
|
||||
radialFg: windowFgActive;
|
||||
radialBg: #00000056;
|
||||
|
||||
placeholderFg: windowSubTextFg;
|
||||
placeholderFgActive: #aaaaaa;
|
||||
inputBorderFg: #e0e0e0;
|
||||
filterInputBorderFg: #54c3f3;
|
||||
checkboxFg: #b3b3b3;
|
||||
|
||||
sliderBgInactive: #e1eaef;
|
||||
sliderBgActive: windowBgActive;
|
||||
|
||||
tooltipBg: #eef2f5;
|
||||
tooltipFg: #5d6c80;
|
||||
tooltipBorderFg: #c9d1db;
|
||||
|
||||
// custom title bar for Windows and macOS
|
||||
titleBg: windowBgOver;
|
||||
titleShadow: #00000003;
|
||||
titleButtonFg: #ababab;
|
||||
titleButtonBgOver: #e5e5e5;
|
||||
titleButtonFgOver: #9a9a9a;
|
||||
titleButtonCloseBgOver: #e81123;
|
||||
titleButtonCloseFgOver: windowFgActive;
|
||||
titleFgActive: #3e3c3e;
|
||||
titleFg: #acacac;
|
||||
|
||||
// tray icon
|
||||
trayCounterBg: #f23c34;
|
||||
trayCounterBgMute: #888888;
|
||||
trayCounterFg: #ffffff;
|
||||
trayCounterBgMacInvert: #ffffff;
|
||||
trayCounterFgMacInvert: #ffffff01;
|
||||
|
||||
// layers
|
||||
layerBg: #0000007f;
|
||||
|
||||
cancelIconFg: menuIconFg;
|
||||
cancelIconFgOver: menuIconFgOver;
|
||||
|
||||
// boxes
|
||||
boxBg: windowBg;
|
||||
boxTextFg: windowFg;
|
||||
boxTextFgGood: #4ab44a;
|
||||
boxTextFgError: #d84d4d;
|
||||
boxTitleFg: #404040;
|
||||
boxSearchBg: boxBg;
|
||||
boxSearchCancelIconFg: cancelIconFg;
|
||||
boxSearchCancelIconFgOver: cancelIconFgOver;
|
||||
|
||||
boxTitleAdditionalFg: #808080;
|
||||
boxTitleCloseFg: cancelIconFg;
|
||||
boxTitleCloseFgOver: cancelIconFgOver;
|
||||
|
||||
membersAboutLimitFg: windowSubTextFgOver;
|
||||
|
||||
contactsBg: windowBg;
|
||||
contactsBgOver: windowBgOver;
|
||||
contactsNameFg: boxTextFg;
|
||||
contactsStatusFg: windowSubTextFg;
|
||||
contactsStatusFgOver: windowSubTextFgOver;
|
||||
contactsStatusFgOnline: windowActiveTextFg;
|
||||
|
||||
photoCropFadeBg: layerBg;
|
||||
photoCropPointFg: #ffffff7f;
|
||||
|
||||
// intro
|
||||
introBg: windowBg;
|
||||
introTitleFg: windowBoldFg;
|
||||
introDescriptionFg: windowSubTextFg;
|
||||
introErrorFg: windowSubTextFg;
|
||||
|
||||
introCoverTopBg: #0f89d0;
|
||||
introCoverBottomBg: #39b0f0;
|
||||
introCoverIconsFg: #5ec6ff;
|
||||
introCoverPlaneTrace: #5ec6ff69;
|
||||
introCoverPlaneInner: #c6d8e8;
|
||||
introCoverPlaneOuter: #a1bed4;
|
||||
introCoverPlaneTop: #ffffff;
|
||||
|
||||
// dialogs
|
||||
dialogsMenuIconFg: menuIconFg;
|
||||
dialogsMenuIconFgOver: menuIconFgOver;
|
||||
|
||||
dialogsBg: windowBg;
|
||||
dialogsNameFg: windowBoldFg;
|
||||
dialogsChatIconFg: dialogsNameFg;
|
||||
dialogsDateFg: windowSubTextFg;
|
||||
dialogsTextFg: windowSubTextFg;
|
||||
dialogsTextFgService: windowActiveTextFg;
|
||||
dialogsDraftFg: #dd4b39;
|
||||
dialogsVerifiedIconBg: windowBgActive;
|
||||
dialogsVerifiedIconFg: windowFgActive;
|
||||
dialogsSendingIconFg: #c1c1c1;
|
||||
dialogsSentIconFg: #5dc452;
|
||||
dialogsUnreadBg: windowBgActive;
|
||||
dialogsUnreadBgMuted: #bbbbbb;
|
||||
dialogsUnreadFg: windowFgActive;
|
||||
|
||||
dialogsBgOver: windowBgOver;
|
||||
dialogsNameFgOver: windowBoldFgOver;
|
||||
dialogsChatIconFgOver: dialogsNameFgOver;
|
||||
dialogsDateFgOver: windowSubTextFgOver;
|
||||
dialogsTextFgOver: windowSubTextFgOver;
|
||||
dialogsTextFgServiceOver: dialogsTextFgService;
|
||||
dialogsDraftFgOver: dialogsDraftFg;
|
||||
dialogsVerifiedIconBgOver: dialogsVerifiedIconBg;
|
||||
dialogsVerifiedIconFgOver: dialogsVerifiedIconFg;
|
||||
dialogsSendingIconFgOver: dialogsSendingIconFg;
|
||||
dialogsSentIconFgOver: dialogsSentIconFg;
|
||||
dialogsUnreadBgOver: dialogsUnreadBg;
|
||||
dialogsUnreadBgMutedOver: dialogsUnreadBgMuted;
|
||||
dialogsUnreadFgOver: dialogsUnreadFg;
|
||||
|
||||
dialogsBgActive: #419fd9;
|
||||
dialogsNameFgActive: windowFgActive;
|
||||
dialogsChatIconFgActive: dialogsNameFgActive;
|
||||
dialogsDateFgActive: windowFgActive;
|
||||
dialogsTextFgActive: windowFgActive;
|
||||
dialogsTextFgServiceActive: dialogsTextFgActive;
|
||||
dialogsDraftFgActive: #c6e1f7;
|
||||
dialogsVerifiedIconBgActive: dialogsTextFgActive;
|
||||
dialogsVerifiedIconFgActive: dialogsBgActive;
|
||||
dialogsSendingIconFgActive: #ffffff99;
|
||||
dialogsSentIconFgActive: dialogsTextFgActive;
|
||||
dialogsUnreadBgActive: dialogsTextFgActive;
|
||||
dialogsUnreadBgMutedActive: dialogsDraftFgActive;
|
||||
dialogsUnreadFgActive: dialogsBgActive;
|
||||
|
||||
dialogsForwardBg: dialogsBgActive;
|
||||
dialogsForwardFg: dialogsNameFgActive;
|
||||
|
||||
searchedBarBg: windowBgOver;
|
||||
searchedBarBorder: shadowFg;
|
||||
searchedBarFg: windowSubTextFgOver;
|
||||
|
||||
// history
|
||||
topBarBg: windowBg;
|
||||
|
||||
emojiPanBg: windowBg;
|
||||
emojiPanCategories: #f7f7f7 | windowBg;
|
||||
emojiPanHeaderFg: windowSubTextFg;
|
||||
emojiPanHeaderBg: #fffffff2 | emojiPanBg;
|
||||
stickerPanDeleteBg: #000000cc;
|
||||
stickerPanDeleteFg: windowFgActive;
|
||||
stickerPreviewBg: #ffffffb0;
|
||||
|
||||
historyTextInFg: windowFg;
|
||||
historyTextOutFg: windowFg;
|
||||
historyCaptionInFg: historyTextInFg;
|
||||
historyCaptionOutFg: historyTextOutFg;
|
||||
historyFileNameInFg: historyTextInFg;
|
||||
historyFileNameOutFg: historyTextOutFg;
|
||||
historyOutIconFg: dialogsSentIconFg;
|
||||
historyOutIconFgSelected: #4da79f;
|
||||
historyIconFgInverted: windowFgActive;
|
||||
historySendingOutIconFg: #98d292;
|
||||
historySendingInIconFg: #a0adb5;
|
||||
historySendingInvertedIconFg: #ffffffc8;
|
||||
|
||||
historySystemBg: #89a0b47f;
|
||||
historySystemBgSelected: #bbc8d4a2;
|
||||
historySystemFg: windowFgActive;
|
||||
|
||||
historyUnreadBarBg: #fcfbfa;
|
||||
historyUnreadBarBorder: shadowFg;
|
||||
historyUnreadBarFg: #538bb4;
|
||||
|
||||
historyForwardChooseBg: #0000004c;
|
||||
historyForwardChooseFg: windowFgActive;
|
||||
|
||||
historyPeer1NameFg: #c03d33; // red
|
||||
historyPeer1UserpicBg: #e17076;
|
||||
historyPeer2NameFg: #4fad2d; // green
|
||||
historyPeer2UserpicBg: #7bc862;
|
||||
historyPeer3NameFg: #d09306; // yellow
|
||||
historyPeer3UserpicBg: #e5ca77;
|
||||
historyPeer4NameFg: windowActiveTextFg; // blue
|
||||
historyPeer4UserpicBg: #65aadd;
|
||||
historyPeer5NameFg: #8544d6; // purple
|
||||
historyPeer5UserpicBg: #a695e7;
|
||||
historyPeer6NameFg: #cd4073; // pink
|
||||
historyPeer6UserpicBg: #ee7aae;
|
||||
historyPeer7NameFg: #2996ad; // sea
|
||||
historyPeer7UserpicBg: #6ec9cb;
|
||||
historyPeer8NameFg: #ce671b; // orange
|
||||
historyPeer8UserpicBg: #faa774;
|
||||
historyPeerUserpicFg: windowFgActive;
|
||||
|
||||
historyScrollBarBg: #556e837a;
|
||||
historyScrollBarBgOver: #556e83bc;
|
||||
historyScrollBg: #556e834c;
|
||||
historyScrollBgOver: #556e836b;
|
||||
|
||||
msgInBg: windowBg;
|
||||
msgInBgSelected: #c2dcf2; // #358cd4 with 30% opacity
|
||||
msgOutBg: #effdde;
|
||||
msgOutBgSelected: #b7dbdb;
|
||||
msgSelectOverlay: #358cd44c;
|
||||
msgStickerOverlay: #358cd47f;
|
||||
msgInServiceFg: windowActiveTextFg;
|
||||
msgInServiceFgSelected: windowActiveTextFg;
|
||||
msgOutServiceFg: #3a8e26;
|
||||
msgOutServiceFgSelected: #367570;
|
||||
msgInShadow: #748ea229;
|
||||
msgInShadowSelected: #548dbb29;
|
||||
msgOutShadow: #3ac34740;
|
||||
msgOutShadowSelected: #37a78e40;
|
||||
msgInDateFg: #a0acb6;
|
||||
msgInDateFgSelected: #6a9cc5;
|
||||
msgOutDateFg: #6cc264;
|
||||
msgOutDateFgSelected: #50a79c;
|
||||
msgServiceFg: windowFgActive;
|
||||
msgServiceBg: #556e837f;
|
||||
msgServiceBgSelected: #8ca0b3a2;
|
||||
msgInReplyBarColor: activeLineFg;
|
||||
msgInReplyBarSelColor: activeLineFg;
|
||||
msgOutReplyBarColor: historyOutIconFg;
|
||||
msgOutReplyBarSelColor: historyOutIconFgSelected;
|
||||
msgImgReplyBarColor: msgServiceFg;
|
||||
msgInMonoFg: #4e7391;
|
||||
msgOutMonoFg: #469165;
|
||||
msgDateImgFg: msgServiceFg;
|
||||
msgDateImgBg: #00000054;
|
||||
msgDateImgBgOver: #00000074;
|
||||
msgDateImgBgSelected: #1c4a7187;
|
||||
|
||||
msgFileThumbLinkInFg: lightButtonFg;
|
||||
msgFileThumbLinkInFgSelected: lightButtonFgOver;
|
||||
msgFileThumbLinkOutFg: #5eba5b;
|
||||
msgFileThumbLinkOutFgSelected: #31a298;
|
||||
msgFileInBg: windowBgActive;
|
||||
msgFileInBgOver: #4eade3;
|
||||
msgFileInBgSelected: #51a3d3;
|
||||
msgFileOutBg: #78c67f;
|
||||
msgFileOutBgOver: #6bc272;
|
||||
msgFileOutBgSelected: #5fb389;
|
||||
|
||||
msgFile1Bg: #72b1df; // blue
|
||||
msgFile1BgDark: #5c9ece;
|
||||
msgFile1BgOver: #5294c4;
|
||||
msgFile1BgSelected: #5099d0;
|
||||
msgFile2Bg: #61b96e; // green
|
||||
msgFile2BgDark: #4da859;
|
||||
msgFile2BgOver: #44a050;
|
||||
msgFile2BgSelected: #46a07e;
|
||||
msgFile3Bg: #e47272; // red
|
||||
msgFile3BgDark: #cd5b5e;
|
||||
msgFile3BgOver: #c35154;
|
||||
msgFile3BgSelected: #9f6a82;
|
||||
msgFile4Bg: #efc274; // yellow
|
||||
msgFile4BgDark: #e6a561;
|
||||
msgFile4BgOver: #dc9c5a;
|
||||
msgFile4BgSelected: #b19d84;
|
||||
|
||||
msgWaveformInActive: windowBgActive;
|
||||
msgWaveformInActiveSelected: #51a3d3;
|
||||
msgWaveformInInactive: #d4dee6;
|
||||
msgWaveformInInactiveSelected: #9cc1e1;
|
||||
msgWaveformOutActive: #78c67f;
|
||||
msgWaveformOutActiveSelected: #6badad;
|
||||
msgWaveformOutInactive: #b3e2b4;
|
||||
msgWaveformOutInactiveSelected: #91c3c3;
|
||||
|
||||
msgBotKbOverBgAdd: #ffffff20;
|
||||
msgBotKbIconFg: msgServiceFg;
|
||||
msgBotKbRippleBg: #00000020;
|
||||
|
||||
mediaInFg: msgInDateFg;
|
||||
mediaInFgSelected: msgInDateFgSelected;
|
||||
mediaOutFg: msgOutDateFg;
|
||||
mediaOutFgSelected: msgOutDateFgSelected;
|
||||
|
||||
youtubePlayIconBg: #e83131c8;
|
||||
youtubePlayIconFg: windowFgActive;
|
||||
videoPlayIconBg: #0000007f;
|
||||
videoPlayIconFg: #ffffff;
|
||||
toastBg: #000000b2;
|
||||
toastFg: windowFgActive;
|
||||
|
||||
reportSpamBg: emojiPanHeaderBg;
|
||||
reportSpamFg: windowFg;
|
||||
|
||||
historyToDownShadow: #00000040;
|
||||
historyComposeAreaBg: msgInBg;
|
||||
historyComposeAreaFg: historyTextInFg;
|
||||
historyComposeAreaFgService: msgInDateFg;
|
||||
historyComposeIconFg: menuIconFg;
|
||||
historyComposeIconFgOver: menuIconFgOver;
|
||||
historySendIconFg: windowBgActive;
|
||||
historySendIconFgOver: windowBgActive;
|
||||
historyPinnedBg: historyComposeAreaBg;
|
||||
historyReplyBg: historyComposeAreaBg;
|
||||
historyReplyIconFg: windowBgActive;
|
||||
historyReplyCancelFg: cancelIconFg;
|
||||
historyReplyCancelFgOver: cancelIconFgOver;
|
||||
|
||||
historyComposeButtonBg: historyComposeAreaBg;
|
||||
historyComposeButtonBgOver: windowBgOver;
|
||||
historyComposeButtonBgRipple: windowBgRipple;
|
||||
|
||||
// overview
|
||||
overviewCheckBg: #00000040;
|
||||
overviewCheckFg: windowBg;
|
||||
overviewCheckFgActive: windowBg;
|
||||
overviewPhotoSelectOverlay: #40ace333;
|
||||
|
||||
// profile
|
||||
profileStatusFgOver: #7c99b2;
|
||||
profileVerifiedCheckBg: windowBgActive;
|
||||
profileVerifiedCheckFg: windowFgActive;
|
||||
|
||||
// settings
|
||||
notificationsBoxMonitorFg: windowFg;
|
||||
notificationsBoxScreenBg: dialogsBgActive; // #6389a8;
|
||||
|
||||
notificationSampleUserpicFg: windowBgActive;
|
||||
notificationSampleCloseFg: #d7d7d7 | windowSubTextFg;
|
||||
notificationSampleTextFg: #d7d7d7 | windowSubTextFg;
|
||||
notificationSampleNameFg: #939393 | windowSubTextFg;
|
||||
|
||||
mainMenuBg: windowBg;
|
||||
mainMenuCoverBg: dialogsBgActive;
|
||||
mainMenuCoverFg: windowFgActive;
|
||||
|
||||
mediaPlayerBg: windowBg;
|
||||
mediaPlayerActiveFg: windowBgActive;
|
||||
mediaPlayerInactiveFg: sliderBgInactive;
|
||||
mediaPlayerDisabledFg: #9dd1ef;
|
||||
|
||||
// mediaview
|
||||
mediaviewFileBg: windowBg;
|
||||
mediaviewFileNameFg: windowFg;
|
||||
mediaviewFileSizeFg: windowSubTextFg;
|
||||
mediaviewFileRedCornerFg: #d55959;
|
||||
mediaviewFileYellowCornerFg: #e8a659;
|
||||
mediaviewFileGreenCornerFg: #49a957;
|
||||
mediaviewFileBlueCornerFg: #599dcf;
|
||||
mediaviewFileExtFg: activeButtonFg;
|
||||
|
||||
mediaviewMenuBg: #383838;
|
||||
mediaviewMenuBgOver: #505050;
|
||||
mediaviewMenuBgRipple: #676767;
|
||||
mediaviewMenuFg: windowFgActive;
|
||||
|
||||
mediaviewBg: #222222eb;
|
||||
mediaviewVideoBg: imageBg;
|
||||
mediaviewControlBg: #0000003c;
|
||||
mediaviewControlFg: windowFgActive;
|
||||
mediaviewCaptionBg: #11111180;
|
||||
mediaviewCaptionFg: mediaviewControlFg;
|
||||
mediaviewTextLinkFg: #91d9ff;
|
||||
mediaviewSaveMsgBg: toastBg;
|
||||
mediaviewSaveMsgFg: toastFg;
|
||||
|
||||
mediaviewPlaybackActive: #c7c7c7;
|
||||
mediaviewPlaybackInactive: #252525;
|
||||
mediaviewPlaybackActiveOver: #ffffff;
|
||||
mediaviewPlaybackInactiveOver: #474747;
|
||||
mediaviewPlaybackProgressFg: #ffffffc7;
|
||||
mediaviewPlaybackIconFg: mediaviewPlaybackActive;
|
||||
mediaviewPlaybackIconFgOver: mediaviewPlaybackActiveOver;
|
||||
mediaviewTransparentBg: #ffffff;
|
||||
mediaviewTransparentFg: #cccccc;
|
||||
|
||||
// notification
|
||||
notificationBg: windowBg;
|
||||
384
Telegram/Resources/default.tdesktop-theme
Normal file
@@ -0,0 +1,384 @@
|
||||
//
|
||||
// This is a sample Telegram Desktop theme file.
|
||||
// It was generated from the 'colors.palette' style file.
|
||||
//
|
||||
// To create a theme with a background image included you should
|
||||
// put two files in a .zip archive:
|
||||
//
|
||||
// First one is the color scheme like the one you're viewing
|
||||
// right now, this file should be named 'colors.tdesktop-theme'.
|
||||
//
|
||||
// Second one should be the background image and it can be named
|
||||
// 'background.jpg', 'background.png', 'tiled.jpg' or 'tiled.png'.
|
||||
// You should name it 'background' (if you'd like it not to be tiled),
|
||||
// or it can be named 'tiled' (if you'd like it to be tiled).
|
||||
//
|
||||
// After that you need to change the extension of your .zip archive
|
||||
// to 'tdesktop-theme', so you'll have:
|
||||
//
|
||||
// mytheme.tdesktop-theme
|
||||
// |-colors.tdesktop-theme
|
||||
// |-background.jpg (or tiled.jpg, background.png, tiled.png)
|
||||
//
|
||||
|
||||
windowBg: #ffffff;
|
||||
windowFg: #000000;
|
||||
windowBgOver: #f1f1f1;
|
||||
windowBgRipple: #e5e5e5;
|
||||
windowFgOver: windowFg;
|
||||
windowSubTextFg: #999999;
|
||||
windowSubTextFgOver: #919191;
|
||||
windowBoldFg: #222222;
|
||||
windowBoldFgOver: #222222;
|
||||
windowBgActive: #40a7e3;
|
||||
windowFgActive: #ffffff;
|
||||
windowActiveTextFg: #168acd;
|
||||
windowShadowFg: #000000;
|
||||
windowShadowFgFallback: #f1f1f1;
|
||||
shadowFg: #00000018;
|
||||
slideFadeOutBg: #0000003c;
|
||||
slideFadeOutShadowFg: windowShadowFg;
|
||||
imageBg: #000000;
|
||||
imageBgTransparent: #ffffff;
|
||||
activeButtonBg: windowBgActive;
|
||||
activeButtonBgOver: #39a5db;
|
||||
activeButtonBgRipple: #2095d0;
|
||||
activeButtonFg: windowFgActive;
|
||||
activeButtonFgOver: activeButtonFg;
|
||||
activeButtonSecondaryFg: #cceeff;
|
||||
activeButtonSecondaryFgOver: activeButtonSecondaryFg;
|
||||
activeLineFg: #37a1de;
|
||||
activeLineFgError: #e48383;
|
||||
lightButtonBg: windowBg;
|
||||
lightButtonBgOver: #e3f1fa;
|
||||
lightButtonBgRipple: #c9e4f6;
|
||||
lightButtonFg: windowActiveTextFg;
|
||||
lightButtonFgOver: lightButtonFg;
|
||||
attentionButtonFg: #d14e4e;
|
||||
attentionButtonFgOver: #d14e4e;
|
||||
attentionButtonBgOver: #fcdfde;
|
||||
attentionButtonBgRipple: #f4c3c2;
|
||||
outlineButtonBg: windowBg;
|
||||
outlineButtonBgOver: lightButtonBgOver;
|
||||
outlineButtonOutlineFg: windowBgActive;
|
||||
outlineButtonBgRipple: lightButtonBgRipple;
|
||||
menuBg: windowBg;
|
||||
menuBgOver: windowBgOver;
|
||||
menuBgRipple: windowBgRipple;
|
||||
menuIconFg: #a8a8a8;
|
||||
menuIconFgOver: #999999;
|
||||
menuSubmenuArrowFg: #373737;
|
||||
menuFgDisabled: #cccccc;
|
||||
menuSeparatorFg: #f1f1f1;
|
||||
scrollBarBg: #00000053;
|
||||
scrollBarBgOver: #0000007a;
|
||||
scrollBg: #0000001a;
|
||||
scrollBgOver: #0000002c;
|
||||
smallCloseIconFg: #c7c7c7;
|
||||
smallCloseIconFgOver: #a3a3a3;
|
||||
radialFg: windowFgActive;
|
||||
radialBg: #00000056;
|
||||
placeholderFg: windowSubTextFg;
|
||||
placeholderFgActive: #aaaaaa;
|
||||
inputBorderFg: #e0e0e0;
|
||||
filterInputBorderFg: #54c3f3;
|
||||
checkboxFg: #b3b3b3;
|
||||
sliderBgInactive: #e1eaef;
|
||||
sliderBgActive: windowBgActive;
|
||||
tooltipBg: #eef2f5;
|
||||
tooltipFg: #5d6c80;
|
||||
tooltipBorderFg: #c9d1db;
|
||||
titleBg: windowBgOver;
|
||||
titleShadow: #00000003;
|
||||
titleButtonFg: #ababab;
|
||||
titleButtonBgOver: #e5e5e5;
|
||||
titleButtonFgOver: #9a9a9a;
|
||||
titleButtonCloseBgOver: #e81123;
|
||||
titleButtonCloseFgOver: windowFgActive;
|
||||
titleFgActive: #3e3c3e;
|
||||
titleFg: #acacac;
|
||||
trayCounterBg: #f23c34;
|
||||
trayCounterBgMute: #888888;
|
||||
trayCounterFg: #ffffff;
|
||||
trayCounterBgMacInvert: #ffffff;
|
||||
trayCounterFgMacInvert: #ffffff01;
|
||||
layerBg: #0000007f;
|
||||
cancelIconFg: menuIconFg;
|
||||
cancelIconFgOver: menuIconFgOver;
|
||||
boxBg: windowBg;
|
||||
boxTextFg: windowFg;
|
||||
boxTextFgGood: #4ab44a;
|
||||
boxTextFgError: #d84d4d;
|
||||
boxTitleFg: #404040;
|
||||
boxSearchBg: boxBg;
|
||||
boxSearchCancelIconFg: cancelIconFg;
|
||||
boxSearchCancelIconFgOver: cancelIconFgOver;
|
||||
boxTitleAdditionalFg: #808080;
|
||||
boxTitleCloseFg: cancelIconFg;
|
||||
boxTitleCloseFgOver: cancelIconFgOver;
|
||||
membersAboutLimitFg: windowSubTextFgOver;
|
||||
contactsBg: windowBg;
|
||||
contactsBgOver: windowBgOver;
|
||||
contactsNameFg: boxTextFg;
|
||||
contactsStatusFg: windowSubTextFg;
|
||||
contactsStatusFgOver: windowSubTextFgOver;
|
||||
contactsStatusFgOnline: windowActiveTextFg;
|
||||
photoCropFadeBg: layerBg;
|
||||
photoCropPointFg: #ffffff7f;
|
||||
introBg: windowBg;
|
||||
introTitleFg: windowBoldFg;
|
||||
introDescriptionFg: windowSubTextFg;
|
||||
introErrorFg: windowSubTextFg;
|
||||
introCoverTopBg: #0f89d0;
|
||||
introCoverBottomBg: #39b0f0;
|
||||
introCoverIconsFg: #5ec6ff;
|
||||
introCoverPlaneTrace: #5ec6ff69;
|
||||
introCoverPlaneInner: #c6d8e8;
|
||||
introCoverPlaneOuter: #a1bed4;
|
||||
introCoverPlaneTop: #ffffff;
|
||||
dialogsMenuIconFg: menuIconFg;
|
||||
dialogsMenuIconFgOver: menuIconFgOver;
|
||||
dialogsBg: windowBg;
|
||||
dialogsNameFg: windowBoldFg;
|
||||
dialogsChatIconFg: dialogsNameFg;
|
||||
dialogsDateFg: windowSubTextFg;
|
||||
dialogsTextFg: windowSubTextFg;
|
||||
dialogsTextFgService: windowActiveTextFg;
|
||||
dialogsDraftFg: #dd4b39;
|
||||
dialogsVerifiedIconBg: windowBgActive;
|
||||
dialogsVerifiedIconFg: windowFgActive;
|
||||
dialogsSendingIconFg: #c1c1c1;
|
||||
dialogsSentIconFg: #5dc452;
|
||||
dialogsUnreadBg: windowBgActive;
|
||||
dialogsUnreadBgMuted: #bbbbbb;
|
||||
dialogsUnreadFg: windowFgActive;
|
||||
dialogsBgOver: windowBgOver;
|
||||
dialogsNameFgOver: windowBoldFgOver;
|
||||
dialogsChatIconFgOver: dialogsNameFgOver;
|
||||
dialogsDateFgOver: windowSubTextFgOver;
|
||||
dialogsTextFgOver: windowSubTextFgOver;
|
||||
dialogsTextFgServiceOver: dialogsTextFgService;
|
||||
dialogsDraftFgOver: dialogsDraftFg;
|
||||
dialogsVerifiedIconBgOver: dialogsVerifiedIconBg;
|
||||
dialogsVerifiedIconFgOver: dialogsVerifiedIconFg;
|
||||
dialogsSendingIconFgOver: dialogsSendingIconFg;
|
||||
dialogsSentIconFgOver: dialogsSentIconFg;
|
||||
dialogsUnreadBgOver: dialogsUnreadBg;
|
||||
dialogsUnreadBgMutedOver: dialogsUnreadBgMuted;
|
||||
dialogsUnreadFgOver: dialogsUnreadFg;
|
||||
dialogsBgActive: #419fd9;
|
||||
dialogsNameFgActive: windowFgActive;
|
||||
dialogsChatIconFgActive: dialogsNameFgActive;
|
||||
dialogsDateFgActive: windowFgActive;
|
||||
dialogsTextFgActive: windowFgActive;
|
||||
dialogsTextFgServiceActive: dialogsTextFgActive;
|
||||
dialogsDraftFgActive: #c6e1f7;
|
||||
dialogsVerifiedIconBgActive: dialogsTextFgActive;
|
||||
dialogsVerifiedIconFgActive: dialogsBgActive;
|
||||
dialogsSendingIconFgActive: #ffffff99;
|
||||
dialogsSentIconFgActive: dialogsTextFgActive;
|
||||
dialogsUnreadBgActive: dialogsTextFgActive;
|
||||
dialogsUnreadBgMutedActive: dialogsDraftFgActive;
|
||||
dialogsUnreadFgActive: dialogsBgActive;
|
||||
dialogsForwardBg: dialogsBgActive;
|
||||
dialogsForwardFg: dialogsNameFgActive;
|
||||
searchedBarBg: windowBgOver;
|
||||
searchedBarBorder: shadowFg;
|
||||
searchedBarFg: windowSubTextFgOver;
|
||||
topBarBg: windowBg;
|
||||
emojiPanBg: windowBg;
|
||||
emojiPanCategories: #f7f7f7; // windowBg;
|
||||
emojiPanHeaderFg: windowSubTextFg;
|
||||
emojiPanHeaderBg: #fffffff2; // emojiPanBg;
|
||||
stickerPanDeleteBg: #000000cc;
|
||||
stickerPanDeleteFg: windowFgActive;
|
||||
stickerPreviewBg: #ffffffb0;
|
||||
historyTextInFg: windowFg;
|
||||
historyTextOutFg: windowFg;
|
||||
historyCaptionInFg: historyTextInFg;
|
||||
historyCaptionOutFg: historyTextOutFg;
|
||||
historyFileNameInFg: historyTextInFg;
|
||||
historyFileNameOutFg: historyTextOutFg;
|
||||
historyOutIconFg: dialogsSentIconFg;
|
||||
historyOutIconFgSelected: #4da79f;
|
||||
historyIconFgInverted: windowFgActive;
|
||||
historySendingOutIconFg: #98d292;
|
||||
historySendingInIconFg: #a0adb5;
|
||||
historySendingInvertedIconFg: #ffffffc8;
|
||||
historySystemBg: #89a0b47f;
|
||||
historySystemBgSelected: #bbc8d4a2;
|
||||
historySystemFg: windowFgActive;
|
||||
historyUnreadBarBg: #fcfbfa;
|
||||
historyUnreadBarBorder: shadowFg;
|
||||
historyUnreadBarFg: #538bb4;
|
||||
historyForwardChooseBg: #0000004c;
|
||||
historyForwardChooseFg: windowFgActive;
|
||||
historyPeer1NameFg: #c03d33;
|
||||
historyPeer1UserpicBg: #e17076;
|
||||
historyPeer2NameFg: #4fad2d;
|
||||
historyPeer2UserpicBg: #7bc862;
|
||||
historyPeer3NameFg: #d09306;
|
||||
historyPeer3UserpicBg: #e5ca77;
|
||||
historyPeer4NameFg: windowActiveTextFg;
|
||||
historyPeer4UserpicBg: #65aadd;
|
||||
historyPeer5NameFg: #8544d6;
|
||||
historyPeer5UserpicBg: #a695e7;
|
||||
historyPeer6NameFg: #cd4073;
|
||||
historyPeer6UserpicBg: #ee7aae;
|
||||
historyPeer7NameFg: #2996ad;
|
||||
historyPeer7UserpicBg: #6ec9cb;
|
||||
historyPeer8NameFg: #ce671b;
|
||||
historyPeer8UserpicBg: #faa774;
|
||||
historyPeerUserpicFg: windowFgActive;
|
||||
historyScrollBarBg: #556e837a;
|
||||
historyScrollBarBgOver: #556e83bc;
|
||||
historyScrollBg: #556e834c;
|
||||
historyScrollBgOver: #556e836b;
|
||||
msgInBg: windowBg;
|
||||
msgInBgSelected: #c2dcf2;
|
||||
msgOutBg: #effdde;
|
||||
msgOutBgSelected: #b7dbdb;
|
||||
msgSelectOverlay: #358cd44c;
|
||||
msgStickerOverlay: #358cd47f;
|
||||
msgInServiceFg: windowActiveTextFg;
|
||||
msgInServiceFgSelected: windowActiveTextFg;
|
||||
msgOutServiceFg: #3a8e26;
|
||||
msgOutServiceFgSelected: #367570;
|
||||
msgInShadow: #748ea229;
|
||||
msgInShadowSelected: #548dbb29;
|
||||
msgOutShadow: #3ac34740;
|
||||
msgOutShadowSelected: #37a78e40;
|
||||
msgInDateFg: #a0acb6;
|
||||
msgInDateFgSelected: #6a9cc5;
|
||||
msgOutDateFg: #6cc264;
|
||||
msgOutDateFgSelected: #50a79c;
|
||||
msgServiceFg: windowFgActive;
|
||||
msgServiceBg: #556e837f;
|
||||
msgServiceBgSelected: #8ca0b3a2;
|
||||
msgInReplyBarColor: activeLineFg;
|
||||
msgInReplyBarSelColor: activeLineFg;
|
||||
msgOutReplyBarColor: historyOutIconFg;
|
||||
msgOutReplyBarSelColor: historyOutIconFgSelected;
|
||||
msgImgReplyBarColor: msgServiceFg;
|
||||
msgInMonoFg: #4e7391;
|
||||
msgOutMonoFg: #469165;
|
||||
msgDateImgFg: msgServiceFg;
|
||||
msgDateImgBg: #00000054;
|
||||
msgDateImgBgOver: #00000074;
|
||||
msgDateImgBgSelected: #1c4a7187;
|
||||
msgFileThumbLinkInFg: lightButtonFg;
|
||||
msgFileThumbLinkInFgSelected: lightButtonFgOver;
|
||||
msgFileThumbLinkOutFg: #5eba5b;
|
||||
msgFileThumbLinkOutFgSelected: #31a298;
|
||||
msgFileInBg: windowBgActive;
|
||||
msgFileInBgOver: #4eade3;
|
||||
msgFileInBgSelected: #51a3d3;
|
||||
msgFileOutBg: #78c67f;
|
||||
msgFileOutBgOver: #6bc272;
|
||||
msgFileOutBgSelected: #5fb389;
|
||||
msgFile1Bg: #72b1df;
|
||||
msgFile1BgDark: #5c9ece;
|
||||
msgFile1BgOver: #5294c4;
|
||||
msgFile1BgSelected: #5099d0;
|
||||
msgFile2Bg: #61b96e;
|
||||
msgFile2BgDark: #4da859;
|
||||
msgFile2BgOver: #44a050;
|
||||
msgFile2BgSelected: #46a07e;
|
||||
msgFile3Bg: #e47272;
|
||||
msgFile3BgDark: #cd5b5e;
|
||||
msgFile3BgOver: #c35154;
|
||||
msgFile3BgSelected: #9f6a82;
|
||||
msgFile4Bg: #efc274;
|
||||
msgFile4BgDark: #e6a561;
|
||||
msgFile4BgOver: #dc9c5a;
|
||||
msgFile4BgSelected: #b19d84;
|
||||
msgWaveformInActive: windowBgActive;
|
||||
msgWaveformInActiveSelected: #51a3d3;
|
||||
msgWaveformInInactive: #d4dee6;
|
||||
msgWaveformInInactiveSelected: #9cc1e1;
|
||||
msgWaveformOutActive: #78c67f;
|
||||
msgWaveformOutActiveSelected: #6badad;
|
||||
msgWaveformOutInactive: #b3e2b4;
|
||||
msgWaveformOutInactiveSelected: #91c3c3;
|
||||
msgBotKbOverBgAdd: #ffffff20;
|
||||
msgBotKbIconFg: msgServiceFg;
|
||||
msgBotKbRippleBg: #00000020;
|
||||
mediaInFg: msgInDateFg;
|
||||
mediaInFgSelected: msgInDateFgSelected;
|
||||
mediaOutFg: msgOutDateFg;
|
||||
mediaOutFgSelected: msgOutDateFgSelected;
|
||||
youtubePlayIconBg: #e83131c8;
|
||||
youtubePlayIconFg: windowFgActive;
|
||||
videoPlayIconBg: #0000007f;
|
||||
videoPlayIconFg: #ffffff;
|
||||
toastBg: #000000b2;
|
||||
toastFg: windowFgActive;
|
||||
reportSpamBg: emojiPanHeaderBg;
|
||||
reportSpamFg: windowFg;
|
||||
historyToDownShadow: #00000040;
|
||||
historyComposeAreaBg: msgInBg;
|
||||
historyComposeAreaFg: historyTextInFg;
|
||||
historyComposeAreaFgService: msgInDateFg;
|
||||
historyComposeIconFg: menuIconFg;
|
||||
historyComposeIconFgOver: menuIconFgOver;
|
||||
historySendIconFg: windowBgActive;
|
||||
historySendIconFgOver: windowBgActive;
|
||||
historyPinnedBg: historyComposeAreaBg;
|
||||
historyReplyBg: historyComposeAreaBg;
|
||||
historyReplyIconFg: windowBgActive;
|
||||
historyReplyCancelFg: cancelIconFg;
|
||||
historyReplyCancelFgOver: cancelIconFgOver;
|
||||
historyComposeButtonBg: historyComposeAreaBg;
|
||||
historyComposeButtonBgOver: windowBgOver;
|
||||
historyComposeButtonBgRipple: windowBgRipple;
|
||||
overviewCheckBg: #00000040;
|
||||
overviewCheckFg: windowBg;
|
||||
overviewCheckFgActive: windowBg;
|
||||
overviewPhotoSelectOverlay: #40ace333;
|
||||
profileStatusFgOver: #7c99b2;
|
||||
profileVerifiedCheckBg: windowBgActive;
|
||||
profileVerifiedCheckFg: windowFgActive;
|
||||
notificationsBoxMonitorFg: windowFg;
|
||||
notificationsBoxScreenBg: dialogsBgActive;
|
||||
notificationSampleUserpicFg: windowBgActive;
|
||||
notificationSampleCloseFg: #d7d7d7; // windowSubTextFg;
|
||||
notificationSampleTextFg: #d7d7d7; // windowSubTextFg;
|
||||
notificationSampleNameFg: #939393; // windowSubTextFg;
|
||||
mainMenuBg: windowBg;
|
||||
mainMenuCoverBg: dialogsBgActive;
|
||||
mainMenuCoverFg: windowFgActive;
|
||||
mediaPlayerBg: windowBg;
|
||||
mediaPlayerActiveFg: windowBgActive;
|
||||
mediaPlayerInactiveFg: sliderBgInactive;
|
||||
mediaPlayerDisabledFg: #9dd1ef;
|
||||
mediaviewFileBg: windowBg;
|
||||
mediaviewFileNameFg: windowFg;
|
||||
mediaviewFileSizeFg: windowSubTextFg;
|
||||
mediaviewFileRedCornerFg: #d55959;
|
||||
mediaviewFileYellowCornerFg: #e8a659;
|
||||
mediaviewFileGreenCornerFg: #49a957;
|
||||
mediaviewFileBlueCornerFg: #599dcf;
|
||||
mediaviewFileExtFg: activeButtonFg;
|
||||
mediaviewMenuBg: #383838;
|
||||
mediaviewMenuBgOver: #505050;
|
||||
mediaviewMenuBgRipple: #676767;
|
||||
mediaviewMenuFg: windowFgActive;
|
||||
mediaviewBg: #222222eb;
|
||||
mediaviewVideoBg: imageBg;
|
||||
mediaviewControlBg: #0000003c;
|
||||
mediaviewControlFg: windowFgActive;
|
||||
mediaviewCaptionBg: #11111180;
|
||||
mediaviewCaptionFg: mediaviewControlFg;
|
||||
mediaviewTextLinkFg: #91d9ff;
|
||||
mediaviewSaveMsgBg: toastBg;
|
||||
mediaviewSaveMsgFg: toastFg;
|
||||
mediaviewPlaybackActive: #c7c7c7;
|
||||
mediaviewPlaybackInactive: #252525;
|
||||
mediaviewPlaybackActiveOver: #ffffff;
|
||||
mediaviewPlaybackInactiveOver: #474747;
|
||||
mediaviewPlaybackProgressFg: #ffffffc7;
|
||||
mediaviewPlaybackIconFg: mediaviewPlaybackActive;
|
||||
mediaviewPlaybackIconFgOver: mediaviewPlaybackActiveOver;
|
||||
mediaviewTransparentBg: #ffffff;
|
||||
mediaviewTransparentFg: #cccccc;
|
||||
notificationBg: windowBg;
|
||||
BIN
Telegram/Resources/icons/add_contact_phone.png
Normal file
|
After Width: | Height: | Size: 380 B |
BIN
Telegram/Resources/icons/add_contact_phone@2x.png
Normal file
|
After Width: | Height: | Size: 708 B |
BIN
Telegram/Resources/icons/add_contact_user.png
Normal file
|
After Width: | Height: | Size: 316 B |
BIN
Telegram/Resources/icons/add_contact_user@2x.png
Normal file
|
After Width: | Height: | Size: 579 B |
BIN
Telegram/Resources/icons/box_button_back.png
Normal file
|
After Width: | Height: | Size: 218 B |
BIN
Telegram/Resources/icons/box_button_back@2x.png
Normal file
|
After Width: | Height: | Size: 282 B |
BIN
Telegram/Resources/icons/box_button_close.png
Normal file
|
After Width: | Height: | Size: 148 B |
BIN
Telegram/Resources/icons/box_button_close@2x.png
Normal file
|
After Width: | Height: | Size: 269 B |
BIN
Telegram/Resources/icons/box_search.png
Normal file
|
After Width: | Height: | Size: 350 B |
BIN
Telegram/Resources/icons/box_search@2x.png
Normal file
|
After Width: | Height: | Size: 707 B |
BIN
Telegram/Resources/icons/bubble_tail.png
Normal file
|
After Width: | Height: | Size: 156 B |
BIN
Telegram/Resources/icons/bubble_tail@2x.png
Normal file
|
After Width: | Height: | Size: 247 B |
BIN
Telegram/Resources/icons/contacts_add.png
Normal file
|
After Width: | Height: | Size: 107 B |
BIN
Telegram/Resources/icons/contacts_add@2x.png
Normal file
|
After Width: | Height: | Size: 126 B |
BIN
Telegram/Resources/icons/dialogs_cancel_search.png
Normal file
|
After Width: | Height: | Size: 197 B |
BIN
Telegram/Resources/icons/dialogs_cancel_search@2x.png
Normal file
|
After Width: | Height: | Size: 273 B |
BIN
Telegram/Resources/icons/dialogs_channel.png
Normal file
|
After Width: | Height: | Size: 253 B |
BIN
Telegram/Resources/icons/dialogs_channel@2x.png
Normal file
|
After Width: | Height: | Size: 433 B |
BIN
Telegram/Resources/icons/dialogs_chat.png
Normal file
|
After Width: | Height: | Size: 265 B |
BIN
Telegram/Resources/icons/dialogs_chat@2x.png
Normal file
|
After Width: | Height: | Size: 490 B |
BIN
Telegram/Resources/icons/dialogs_lock.png
Normal file
|
After Width: | Height: | Size: 285 B |
BIN
Telegram/Resources/icons/dialogs_lock@2x.png
Normal file
|
After Width: | Height: | Size: 444 B |
BIN
Telegram/Resources/icons/dialogs_menu.png
Normal file
|
After Width: | Height: | Size: 110 B |
BIN
Telegram/Resources/icons/dialogs_menu@2x.png
Normal file
|
After Width: | Height: | Size: 148 B |
BIN
Telegram/Resources/icons/dialogs_pinned.png
Normal file
|
After Width: | Height: | Size: 307 B |
BIN
Telegram/Resources/icons/dialogs_pinned@2x.png
Normal file
|
After Width: | Height: | Size: 541 B |
BIN
Telegram/Resources/icons/dialogs_received.png
Normal file
|
After Width: | Height: | Size: 158 B |
BIN
Telegram/Resources/icons/dialogs_received@2x.png
Normal file
|
After Width: | Height: | Size: 309 B |
BIN
Telegram/Resources/icons/dialogs_sending.png
Normal file
|
After Width: | Height: | Size: 223 B |
BIN
Telegram/Resources/icons/dialogs_sending@2x.png
Normal file
|
After Width: | Height: | Size: 432 B |
BIN
Telegram/Resources/icons/dialogs_sent.png
Normal file
|
After Width: | Height: | Size: 145 B |
BIN
Telegram/Resources/icons/dialogs_sent@2x.png
Normal file
|
After Width: | Height: | Size: 261 B |
BIN
Telegram/Resources/icons/dialogs_unlock.png
Normal file
|
After Width: | Height: | Size: 287 B |
BIN
Telegram/Resources/icons/dialogs_unlock@2x.png
Normal file
|
After Width: | Height: | Size: 450 B |
BIN
Telegram/Resources/icons/dialogs_verified_check.png
Normal file
|
After Width: | Height: | Size: 180 B |
BIN
Telegram/Resources/icons/dialogs_verified_check@2x.png
Normal file
|
After Width: | Height: | Size: 281 B |
BIN
Telegram/Resources/icons/dialogs_verified_star.png
Normal file
|
After Width: | Height: | Size: 342 B |
BIN
Telegram/Resources/icons/dialogs_verified_star@2x.png
Normal file
|
After Width: | Height: | Size: 660 B |