2016-07-11 18:05:46 +00:00
|
|
|
/*
|
|
|
|
This file is part of Telegram Desktop,
|
2018-01-03 10:23:14 +00:00
|
|
|
the official desktop application for the Telegram messaging service.
|
2016-07-11 18:05:46 +00:00
|
|
|
|
2018-01-03 10:23:14 +00:00
|
|
|
For license and copyright information please follow this link:
|
|
|
|
https://github.com/telegramdesktop/tdesktop/blob/master/LEGAL
|
2016-07-11 18:05:46 +00:00
|
|
|
*/
|
|
|
|
|
2019-09-17 16:13:12 +00:00
|
|
|
using "ui/basic.style";
|
2016-07-11 18:05:46 +00:00
|
|
|
using "ui/widgets/widgets.style";
|
|
|
|
|
|
|
|
mediaviewOverDuration: 150;
|
2016-12-21 15:05:58 +00:00
|
|
|
|
2016-09-23 16:04:26 +00:00
|
|
|
mediaviewPlayback: MediaSlider {
|
|
|
|
width: 3px;
|
|
|
|
activeFg: mediaviewPlaybackActive;
|
|
|
|
inactiveFg: mediaviewPlaybackInactive;
|
2016-11-01 12:46:34 +00:00
|
|
|
activeFgOver: mediaviewPlaybackActiveOver;
|
2019-03-05 11:06:54 +00:00
|
|
|
inactiveFgOver: mediaviewPlaybackInactive;
|
2016-11-01 12:46:34 +00:00
|
|
|
activeFgDisabled: mediaviewPlaybackActive;
|
|
|
|
inactiveFgDisabled: mediaviewPlaybackInactive;
|
2019-03-05 11:06:54 +00:00
|
|
|
receivedTillFg: mediaviewPlaybackInactiveOver;
|
2020-01-31 09:54:57 +00:00
|
|
|
seekSize: size(12px, 12px);
|
2016-09-23 16:04:26 +00:00
|
|
|
duration: mediaviewOverDuration;
|
|
|
|
}
|
2020-01-31 09:54:57 +00:00
|
|
|
mediaviewPlaybackTop: 52px;
|
2016-09-23 16:04:26 +00:00
|
|
|
|
2020-01-31 09:54:57 +00:00
|
|
|
mediaviewControlsButton: IconButton {
|
|
|
|
ripple: RippleAnimation(defaultRippleAnimation) {
|
|
|
|
color: mediaviewPlaybackIconRipple;
|
|
|
|
}
|
|
|
|
rippleAreaPosition: point(0px, 0px);
|
|
|
|
duration: mediaviewOverDuration;
|
|
|
|
}
|
|
|
|
|
|
|
|
mediaviewControllerSize: size(481px, 75px);
|
2016-07-11 18:05:46 +00:00
|
|
|
mediaviewPlayProgressLabel: LabelSimple(defaultLabelSimple) {
|
2016-07-12 11:38:16 +00:00
|
|
|
font: semiboldFont;
|
2016-12-21 15:05:58 +00:00
|
|
|
textFg: mediaviewPlaybackProgressFg;
|
2016-07-11 18:05:46 +00:00
|
|
|
}
|
2020-01-31 09:54:57 +00:00
|
|
|
mediaviewPlayProgressSkip: 8px;
|
|
|
|
mediaviewPlayProgressLeft: 8px;
|
|
|
|
mediaviewPlayButtonTop: 5px;
|
|
|
|
mediaviewPlayButton: IconButton(mediaviewControlsButton) {
|
|
|
|
width: 42px;
|
|
|
|
height: 42px;
|
|
|
|
rippleAreaSize: 42px;
|
2016-07-11 18:05:46 +00:00
|
|
|
|
2020-01-31 09:54:57 +00:00
|
|
|
icon: icon {{ "player_play", mediaviewPlaybackIconFg }};
|
|
|
|
iconOver: icon {{ "player_play", mediaviewPlaybackIconFgOver }};
|
|
|
|
iconPosition: point(9px, 9px);
|
|
|
|
}
|
|
|
|
mediaviewPauseIcon: icon {{ "player_pause", mediaviewPlaybackIconFg }};
|
|
|
|
mediaviewPauseIconOver: icon {{ "player_pause", mediaviewPlaybackIconFgOver }};
|
2016-07-11 18:05:46 +00:00
|
|
|
|
2020-01-31 09:54:57 +00:00
|
|
|
mediaviewButtonsTop: 7px;
|
|
|
|
|
|
|
|
mediaviewMenuToggleSkip: 4px;
|
|
|
|
mediaviewMenuToggle: IconButton(mediaviewControlsButton) {
|
|
|
|
width: 34px;
|
|
|
|
height: 34px;
|
|
|
|
rippleAreaSize: 34px;
|
|
|
|
icon: icon {{ "player_more", mediaviewPlaybackIconFg }};
|
|
|
|
iconOver: icon {{ "player_more", mediaviewPlaybackIconFgOver }};
|
|
|
|
iconPosition: point(5px, 5px);
|
|
|
|
}
|
|
|
|
|
|
|
|
mediaviewPipButtonSkip: 5px;
|
|
|
|
mediaviewPipButton: IconButton(mediaviewMenuToggle) {
|
|
|
|
icon: icon {{ "player_pip", mediaviewPlaybackIconFg }};
|
|
|
|
iconOver: icon {{ "player_pip", mediaviewPlaybackIconFgOver }};
|
2016-07-11 18:05:46 +00:00
|
|
|
}
|
2020-01-28 13:48:25 +00:00
|
|
|
|
2020-01-31 09:54:57 +00:00
|
|
|
mediaviewFullScreenButtonSkip: 8px;
|
|
|
|
mediaviewFullScreenButton: IconButton(mediaviewMenuToggle) {
|
|
|
|
icon: icon {{ "player_fullscreen", mediaviewPlaybackIconFg }};
|
|
|
|
iconOver: icon {{ "player_fullscreen", mediaviewPlaybackIconFgOver }};
|
|
|
|
}
|
|
|
|
mediaviewFullScreenOutIcon: icon {{ "player_minimize", mediaviewPlaybackIconFg }};
|
|
|
|
mediaviewFullScreenOutIconOver: icon {{ "player_minimize", mediaviewPlaybackIconFgOver }};
|
|
|
|
|
|
|
|
mediaviewVolumeWidth: 75px;
|
|
|
|
mediaviewControllerRadius: 9px;
|
|
|
|
|
|
|
|
mediaviewVolumeIcon0: icon {{ "player_volume_off", mediaviewPlaybackIconFg }};
|
|
|
|
mediaviewVolumeIcon0Over: icon {{ "player_volume_off", mediaviewPlaybackIconFgOver }};
|
|
|
|
mediaviewVolumeIcon1: icon {{ "player_volume_small", mediaviewPlaybackIconFg }};
|
|
|
|
mediaviewVolumeIcon1Over: icon {{ "player_volume_small", mediaviewPlaybackIconFgOver }};
|
|
|
|
mediaviewVolumeIcon2: icon {{ "player_volume_on", mediaviewPlaybackIconFg }};
|
|
|
|
mediaviewVolumeIcon2Over: icon {{ "player_volume_on", mediaviewPlaybackIconFgOver }};
|
|
|
|
mediaviewVolumeTop: 10px;
|
|
|
|
mediaviewVolumeToggleSkip: 11px;
|
|
|
|
mediaviewVolumeToggle: IconButton(mediaviewControlsButton) {
|
|
|
|
width: 30px;
|
|
|
|
height: 30px;
|
|
|
|
rippleAreaSize: 30px;
|
2020-01-28 13:48:25 +00:00
|
|
|
icon: mediaviewVolumeIcon0;
|
|
|
|
iconOver: mediaviewVolumeIcon0Over;
|
2020-01-31 09:54:57 +00:00
|
|
|
iconPosition: point(3px, 3px);
|
2020-01-28 13:48:25 +00:00
|
|
|
}
|
2020-01-31 09:54:57 +00:00
|
|
|
mediaviewVolumeSkip: 4px;
|
2020-01-28 13:48:25 +00:00
|
|
|
|
2016-12-21 15:05:58 +00:00
|
|
|
mediaviewLeft: icon {{ "mediaview_next-flip_horizontal", mediaviewControlFg }};
|
|
|
|
mediaviewRight: icon {{ "mediaview_next", mediaviewControlFg }};
|
|
|
|
mediaviewClose: icon {{ "mediaview_close", mediaviewControlFg }};
|
|
|
|
mediaviewSave: icon {{ "mediaview_download", mediaviewControlFg }};
|
2020-02-05 15:27:53 +00:00
|
|
|
mediaviewRotate: icon {{ "mediaview_rotate", mediaviewControlFg }};
|
2016-12-21 15:05:58 +00:00
|
|
|
mediaviewMore: icon {{ "mediaview_more", mediaviewControlFg }};
|
2016-09-30 16:40:00 +00:00
|
|
|
|
|
|
|
mediaviewFileRed: icon {
|
2016-10-31 12:29:26 +00:00
|
|
|
{ size(25px, 25px), mediaviewFileBg },
|
2016-10-22 18:58:25 +00:00
|
|
|
{ "mediaview_file_corner", mediaviewFileRedCornerFg },
|
2016-09-30 16:40:00 +00:00
|
|
|
};
|
|
|
|
mediaviewFileYellow: icon {
|
2016-10-31 12:29:26 +00:00
|
|
|
{ size(25px, 25px), mediaviewFileBg },
|
2016-10-22 18:58:25 +00:00
|
|
|
{ "mediaview_file_corner", mediaviewFileYellowCornerFg },
|
2016-09-30 16:40:00 +00:00
|
|
|
};
|
|
|
|
mediaviewFileGreen: icon {
|
2016-10-31 12:29:26 +00:00
|
|
|
{ size(25px, 25px), mediaviewFileBg },
|
2016-10-22 18:58:25 +00:00
|
|
|
{ "mediaview_file_corner", mediaviewFileGreenCornerFg },
|
2016-09-30 16:40:00 +00:00
|
|
|
};
|
|
|
|
mediaviewFileBlue: icon {
|
2016-10-31 12:29:26 +00:00
|
|
|
{ size(25px, 25px), mediaviewFileBg },
|
2016-10-22 18:58:25 +00:00
|
|
|
{ "mediaview_file_corner", mediaviewFileBlueCornerFg },
|
2016-09-30 16:40:00 +00:00
|
|
|
};
|
2016-10-22 18:58:25 +00:00
|
|
|
|
2016-10-31 12:29:26 +00:00
|
|
|
mediaviewFilePadding: 18px;
|
|
|
|
mediaviewFileSize: size(340px, 116px);
|
|
|
|
mediaviewFileNameTop: 4px;
|
|
|
|
mediaviewFileNameFont: font(semibold 14px);
|
|
|
|
mediaviewFileSizeTop: 29px;
|
|
|
|
mediaviewFileExtTop: 35px;
|
|
|
|
mediaviewFileExtFont: font(semibold 18px);
|
|
|
|
mediaviewFileExtPadding: 10px;
|
|
|
|
mediaviewFileLinksTop: 57px;
|
|
|
|
mediaviewFileIconSize: 80px;
|
|
|
|
|
2016-12-21 15:05:58 +00:00
|
|
|
mediaviewFileLink: defaultLinkButton;
|
2016-10-31 12:29:26 +00:00
|
|
|
|
2016-10-26 16:43:13 +00:00
|
|
|
mediaviewMenu: Menu(defaultMenu) {
|
2016-10-31 12:29:26 +00:00
|
|
|
itemBg: mediaviewMenuBg;
|
|
|
|
itemBgOver: mediaviewMenuBgOver;
|
|
|
|
itemFg: mediaviewMenuFg;
|
|
|
|
itemFgOver: mediaviewMenuFg;
|
|
|
|
itemFgDisabled: mediaviewMenuFg;
|
|
|
|
itemFgShortcut: mediaviewMenuFg;
|
|
|
|
itemFgShortcutOver: mediaviewMenuFg;
|
|
|
|
itemFgShortcutDisabled: mediaviewMenuFg;
|
|
|
|
|
|
|
|
separatorFg: mediaviewMenuFg;
|
2016-11-16 16:04:25 +00:00
|
|
|
|
|
|
|
ripple: RippleAnimation(defaultRippleAnimation) {
|
|
|
|
color: mediaviewMenuBgRipple;
|
|
|
|
}
|
2016-10-26 16:43:13 +00:00
|
|
|
}
|
2016-11-09 13:40:51 +00:00
|
|
|
mediaviewMenuShadow: Shadow(defaultEmptyShadow) {
|
|
|
|
fallback: mediaviewMenuBg;
|
|
|
|
}
|
|
|
|
mediaviewPanelAnimation: PanelAnimation(defaultPanelAnimation) {
|
|
|
|
fadeBg: mediaviewMenuBg;
|
|
|
|
shadow: mediaviewMenuShadow;
|
|
|
|
}
|
2016-10-26 16:43:13 +00:00
|
|
|
mediaviewPopupMenu: PopupMenu(defaultPopupMenu) {
|
2016-11-09 13:40:51 +00:00
|
|
|
shadow: mediaviewMenuShadow;
|
2016-10-26 16:43:13 +00:00
|
|
|
menu: mediaviewMenu;
|
2016-11-09 13:40:51 +00:00
|
|
|
animation: mediaviewPanelAnimation;
|
2016-10-26 16:43:13 +00:00
|
|
|
}
|
|
|
|
mediaviewDropdownMenu: DropdownMenu(defaultDropdownMenu) {
|
|
|
|
menu: mediaviewMenu;
|
2016-11-09 13:40:51 +00:00
|
|
|
wrap: InnerDropdown(defaultInnerDropdown) {
|
|
|
|
bg: mediaviewMenuBg;
|
|
|
|
animation: mediaviewPanelAnimation;
|
|
|
|
scrollPadding: margins(0px, 8px, 0px, 8px);
|
|
|
|
shadow: mediaviewMenuShadow;
|
|
|
|
}
|
2016-10-26 16:43:13 +00:00
|
|
|
}
|
2016-12-23 13:21:01 +00:00
|
|
|
|
2020-01-31 12:14:21 +00:00
|
|
|
mediaviewControlsMenu: Menu(defaultMenu) {
|
|
|
|
itemBg: mediaviewSaveMsgBg;
|
|
|
|
itemBgOver: mediaviewPlaybackIconRipple;
|
|
|
|
itemFg: mediaviewPlaybackProgressFg;
|
|
|
|
itemFgOver: mediaviewPlaybackProgressFg;
|
|
|
|
itemFgDisabled: mediaviewPlaybackProgressFg;
|
|
|
|
itemFgShortcut: mediaviewPlaybackProgressFg;
|
|
|
|
itemFgShortcutOver: mediaviewPlaybackProgressFg;
|
|
|
|
itemFgShortcutDisabled: mediaviewPlaybackProgressFg;
|
|
|
|
|
|
|
|
separatorFg: mediaviewPlaybackIconRipple;
|
|
|
|
|
|
|
|
arrow: icon {{ "dropdown_submenu_arrow", mediaviewPlaybackProgressFg }};
|
|
|
|
|
|
|
|
ripple: RippleAnimation(defaultRippleAnimation) {
|
|
|
|
color: mediaviewPlaybackIconRipple;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
mediaviewControlsMenuShadow: Shadow(defaultEmptyShadow) {
|
|
|
|
fallback: mediaviewSaveMsgBg;
|
|
|
|
}
|
|
|
|
mediaviewControlsPanelAnimation: PanelAnimation(defaultPanelAnimation) {
|
|
|
|
fadeBg: mediaviewSaveMsgBg;
|
|
|
|
shadow: mediaviewControlsMenuShadow;
|
|
|
|
}
|
|
|
|
mediaviewControlsPopupMenu: PopupMenu(defaultPopupMenu) {
|
|
|
|
shadow: mediaviewControlsMenuShadow;
|
|
|
|
menu: mediaviewControlsMenu;
|
|
|
|
animation: mediaviewControlsPanelAnimation;
|
|
|
|
}
|
|
|
|
mediaviewMenuCheck: icon {{ "player_check", mediaviewPlaybackProgressFg }};
|
|
|
|
|
2016-12-23 13:21:01 +00:00
|
|
|
mediaviewSaveMsgCheck: icon {{ "mediaview_save_check", mediaviewSaveMsgFg }};
|
|
|
|
mediaviewSaveMsgPadding: margins(55px, 19px, 29px, 20px);
|
|
|
|
mediaviewSaveMsgCheckPos: point(23px, 21px);
|
|
|
|
mediaviewSaveMsgShowing: 200;
|
|
|
|
mediaviewSaveMsgShown: 2000;
|
|
|
|
mediaviewSaveMsgHiding: 2500;
|
|
|
|
mediaviewSaveMsgStyle: TextStyle(defaultTextStyle) {
|
|
|
|
font: font(16px);
|
|
|
|
linkFont: font(16px);
|
|
|
|
linkFontOver: font(16px underline);
|
|
|
|
}
|
|
|
|
mediaviewTextPalette: TextPalette(defaultTextPalette) {
|
|
|
|
linkFg: mediaviewTextLinkFg;
|
2018-05-24 13:03:21 +00:00
|
|
|
monoFg: mediaviewCaptionFg;
|
2016-12-23 13:21:01 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
mediaviewCaptionStyle: defaultTextStyle;
|
|
|
|
|
|
|
|
mediaviewThickFont: semiboldFont;
|
|
|
|
mediaviewFont: normalFont;
|
|
|
|
mediaviewTextStyle: defaultTextStyle;
|
|
|
|
|
|
|
|
mediaviewTextLeft: 16px;
|
|
|
|
mediaviewTextSkip: 10px;
|
|
|
|
mediaviewHeaderTop: 48px;
|
|
|
|
mediaviewTextTop: 24px;
|
|
|
|
mediaviewTextOpacity: 0.5;
|
|
|
|
mediaviewTextOverOpacity: 1;
|
|
|
|
|
|
|
|
mediaviewIconOpacity: 0.45;
|
|
|
|
mediaviewIconOverOpacity: 1;
|
|
|
|
mediaviewControlBgOpacity: 0.3;
|
|
|
|
mediaviewControlMargin: 0px;
|
|
|
|
mediaviewControlSize: 90px;
|
|
|
|
mediaviewIconSize: size(60px, 56px);
|
|
|
|
|
|
|
|
mediaviewWaitHide: 2000;
|
|
|
|
mediaviewHideDuration: 1000;
|
|
|
|
mediaviewShowDuration: 200;
|
|
|
|
mediaviewFadeDuration: 150;
|
|
|
|
|
|
|
|
mediaviewDeltaFromLastAction: 5px;
|
|
|
|
mediaviewSwipeDistance: 80px;
|
|
|
|
|
|
|
|
mediaviewCaptionPadding: margins(18px, 10px, 18px, 10px);
|
|
|
|
mediaviewCaptionMargin: size(11px, 11px);
|
|
|
|
mediaviewCaptionRadius: 2px;
|
|
|
|
|
2017-12-28 14:58:34 +00:00
|
|
|
mediaviewGroupPadding: margins(0px, 14px, 0px, 14px);
|
|
|
|
mediaviewGroupHeight: 80px;
|
|
|
|
mediaviewGroupWidth: 56px;
|
|
|
|
mediaviewGroupWidthMax: 160px;
|
|
|
|
mediaviewGroupSkip: 3px;
|
|
|
|
mediaviewGroupSkipCurrent: 12px;
|
|
|
|
|
2016-12-23 13:21:01 +00:00
|
|
|
themePreviewSize: size(903px, 584px);
|
|
|
|
themePreviewBg: windowBg;
|
2016-12-31 15:19:22 +00:00
|
|
|
themePreviewOverlayOpacity: 0.8;
|
2019-09-09 13:13:16 +00:00
|
|
|
themePreviewMargin: margins(36px, 72px, 36px, 88px);
|
|
|
|
themePreviewTitleTop: 24px;
|
2016-12-23 13:21:01 +00:00
|
|
|
themePreviewTitleFg: windowBoldFg;
|
|
|
|
themePreviewTitleFont: font(17px semibold);
|
|
|
|
themePreviewLoadingFont: font(16px);
|
|
|
|
themePreviewLoadingFg: windowSubTextFg;
|
|
|
|
themePreviewApplyButton: RoundButton(defaultActiveButton) {
|
|
|
|
height: 38px;
|
|
|
|
font: font(15px semibold);
|
|
|
|
}
|
|
|
|
themePreviewCancelButton: RoundButton(defaultLightButton) {
|
|
|
|
height: 38px;
|
|
|
|
font: font(15px semibold);
|
|
|
|
}
|
|
|
|
themePreviewButtonsSkip: 20px;
|
|
|
|
themePreviewDialogsWidth: 312px;
|
2020-01-03 11:18:38 +00:00
|
|
|
|
2020-01-06 17:54:11 +00:00
|
|
|
pipDefaultSize: 320px;
|
2020-02-03 17:24:45 +00:00
|
|
|
pipMinimalSize: 120px;
|
2020-01-03 11:18:38 +00:00
|
|
|
pipBorderSkip: 20px;
|
2020-01-03 13:22:59 +00:00
|
|
|
pipBorderSnapArea: 16px;
|
2020-01-31 09:54:57 +00:00
|
|
|
pipResizeArea: 10px;
|
|
|
|
pipControlSkip: 6px;
|
|
|
|
pipPlaybackWidth: 2px;
|
2020-02-03 15:48:25 +00:00
|
|
|
pipPlaybackWide: 4px;
|
2020-01-31 09:54:57 +00:00
|
|
|
pipPlaybackSkip: 4px;
|
2020-02-03 17:24:45 +00:00
|
|
|
pipPlaybackTextSkip: 6px;
|
|
|
|
pipPlaybackFont: font(11px);
|
2020-01-31 09:54:57 +00:00
|
|
|
pipPlayIcon: icon {{ "player_pip_play", mediaviewPipControlsFg }};
|
|
|
|
pipPlayIconOver: icon {{ "player_pip_play", mediaviewPipControlsFgOver }};
|
|
|
|
pipPauseIcon: icon {{ "player_pip_pause", mediaviewPipControlsFg }};
|
|
|
|
pipPauseIconOver: icon {{ "player_pip_pause", mediaviewPipControlsFgOver }};
|
|
|
|
pipCloseIcon: icon {{ "player_pip_close", mediaviewPlaybackIconFg }};
|
|
|
|
pipCloseIconOver: icon {{ "player_pip_close", mediaviewPlaybackIconFgOver }};
|
|
|
|
pipEnlargeIcon: icon {{ "player_pip_enlarge", mediaviewPlaybackIconFg }};
|
|
|
|
pipEnlargeIconOver: icon {{ "player_pip_enlarge", mediaviewPlaybackIconFgOver }};
|