Skip to content
Commits on Source (17)
[submodule "subprojects/gtk-frdp"]
path = subprojects/gtk-frdp
url = https://gitlab.gnome.org/gnome/gtk-frdp.git
branch = gtk-frdp-0-1
branch = master
44.beta - 11 Feb, 2023
=====================
Changes since 43.0
- Update gtk-frdp
- Allow resizing of remote desktops
- Use app-id for icon name
- Keep aspect ratios of remote desktops
- Fix position of cursor for original scale
- Switch to master branch of gtk-frdp
- Use GNOME module post_install with meson
- Added/updated/fixed translations:
- Belarusian
- French
- Russian
43.0 - 16 Sep, 2022
=====================
......
......@@ -83,8 +83,7 @@
"sources" : [
{
"type" : "git",
"url" : "https://gitlab.gnome.org/gnome/gtk-frdp.git",
"branch" : "a44d84ec687f41ad37e43697b28a018f65780780"
"url" : "https://gitlab.gnome.org/gnome/gtk-frdp.git"
}
]
},
......
#!/usr/bin/env python3
from os import environ, path
from subprocess import call
prefix = environ.get('MESON_INSTALL_PREFIX', '/usr/local')
datadir = path.join(prefix, 'share')
destdir = environ.get('DESTDIR', '')
# Package managers set this so we don't need to run
if not destdir:
print('Updating icon cache...')
call(['gtk-update-icon-cache', '-qtf', path.join(datadir, 'icons', 'hicolor')])
print('Updating desktop database...')
call(['update-desktop-database', '-q', path.join(datadir, 'applications')])
print('Compiling GSettings schemas...')
call(['glib-compile-schemas', path.join(datadir, 'glib-2.0', 'schemas')])
......@@ -63,7 +63,8 @@ install_data(
icon_dir = join_paths('icons', 'hicolor', 'symbolic', 'apps')
install_data(
join_paths(icon_dir, 'org.gnome.Connections-symbolic.svg'),
install_dir: join_paths(get_option('datadir'), icon_dir)
install_dir: join_paths(get_option('datadir'), icon_dir),
rename: '@0@-symbolic.svg'.format(application_id)
)
install_data('org.gnome.Connections.gschema.xml',
......
......@@ -2,14 +2,15 @@
# Copyright (C) 2021 gnome-connections's COPYRIGHT HOLDER
# This file is distributed under the same license as the gnome-connections package.
# Guillaume Bernard <associations@guillaume-bernard.fr>, 2021.
# Charles Monzat <charles.monzat@free.fr>, 2022.
#
msgid ""
msgstr ""
"Project-Id-Version: gnome-connections master\n"
"POT-Creation-Date: 2021-09-11 09:15+0000\n"
"PO-Revision-Date: 2021-12-07 11:59+0100\n"
"Last-Translator: Guillaume Bernard <associations@guillaume-bernard.fr>\n"
"Language-Team: French <gnomefr@traduc.org>\n"
"POT-Creation-Date: 2022-03-21 12:15+0000\n"
"PO-Revision-Date: 2022-04-11 10:37+0200\n"
"Last-Translator: Charles Monzat <charles.monzat@free.fr>\n"
"Language-Team: GNOME French Team <gnomefr@traduc.org>\n"
"Language: fr\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
......@@ -116,21 +117,18 @@ msgstr "La machine distante s’ouvrira dans la vue de la collection."
#. (itstool) path: info/title
#: C/index.page:7
#| msgid "Connections"
msgctxt "link:trail"
msgid "Connections"
msgstr "Connexions"
#. (itstool) path: info/title
#: C/index.page:8
#| msgid "Connections"
msgctxt "link"
msgid "Connections"
msgstr "Connexions"
#. (itstool) path: info/title
#: C/index.page:9
#| msgid "Connections"
msgctxt "text"
msgid "Connections"
msgstr "Connexions"
......@@ -163,8 +161,8 @@ msgstr "Premiers pas"
#: C/legal.xml:4
msgid "Creative Commons Attribution-Share Alike 3.0 Unported License"
msgstr ""
"Licence Creative Commons Paternité-Partage dans les conditions Identiques à "
"l’Initiale 3.0 non transposé"
"Licence Creative Commons Attribution - Partage dans les Mêmes Conditions 3.0 "
"non transposé"
#. (itstool) path: license/p
#: C/legal.xml:3
......
project('gnome-connections', ['c', 'vala'],
version: '43.0',
meson_version: '>= 0.50.0',
version: '44.beta',
meson_version: '>= 0.59.0',
default_options: [ 'warning_level=2',
],
)
......@@ -48,4 +48,8 @@ subdir('help')
subdir('src')
subdir('po')
meson.add_install_script('build-aux/meson/postinstall.py')
gnome.post_install(
glib_compile_schemas: true,
gtk_update_icon_cache: true,
update_desktop_database: true,
)
# Belarusian translation for connections.
# Copyright (C) 2021 connections's COPYRIGHT HOLDER
# This file is distributed under the same license as the connections package.
# 3abac <3abac@3a.by>, 2021.
#
msgid ""
msgstr ""
"Project-Id-Version: gnome-connections master\n"
"Report-Msgid-Bugs-To: https://gitlab.gnome.org/GNOME/connections/issues\n"
"POT-Creation-Date: 2022-11-24 23:06+0000\n"
"PO-Revision-Date: 2022-11-28 03:30+0300\n"
"Last-Translator: Launchpad translators\n"
"Language-Team: Belarusian <i18n-bel-gnome@googlegroups.com>\n"
"Language: be\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=3; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n"
"%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);\n"
"X-Generator: Poedit 3.2\n"
#: data/org.gnome.Connections.appdata.xml.in:7
#: data/org.gnome.Connections.desktop.in:3 src/application.vala:92
#: src/ui/topbar.ui:9 src/ui/window.ui:5 src/window.vala:106
msgid "Connections"
msgstr "Connections"
#: data/org.gnome.Connections.appdata.xml.in:8
msgid "View and use other desktops"
msgstr "Прагляд і выкарыстанне іншых працоўных сталоў"
#: data/org.gnome.Connections.appdata.xml.in:10
msgid ""
"Connections allows you to connect to and use other desktops. This can be a "
"great way to access content or software on a different desktop operating "
"system. It can also be used as a way to provide support to users who might "
"need help."
msgstr ""
"Connections дазваляе падлучацца да іншых працоўных сталоў і выкарыстоўваць "
"іх. Гэта можа быць выдатным спосабам доступу да змесціва або праграмнага "
"забеспячэння на камп'ютары з іншай аперацыйнай сістэмай. Таксама можна "
"выкарыстоўваць для забеспячэння падтрымкі тых карыстальнікаў, якім можа "
"спатрэбіцца дапамога."
#: data/org.gnome.Connections.appdata.xml.in:13
msgid ""
"A range of different operating systems can be connected to, including Linux "
"and Windows desktops. You can also connect to virtual machines."
msgstr ""
"Шэраг аперацыйных сістэм да якіх магчыма падлучыцца, у іх ліку Linux і "
"Windows. А таксама можна падлучацца да віртуальных машын."
#: data/org.gnome.Connections.appdata.xml.in:16
msgid ""
"Connections uses the widely supported VNC and RDP protocols, and one of "
"these must be enabled on the desktop that you want to connect to."
msgstr ""
"Connections выкарыстоўвае шырока распаўсюджаныя пратаколы VNC і RDP, адзін з "
"іх павінен быць уключаны на камп'ютары, да якога вы збіраецеся далучыцца."
#: data/org.gnome.Connections.appdata.xml.in:43
msgid "The GNOME Project"
msgstr "Праект GNOME"
#: data/org.gnome.Connections.desktop.in:8
msgid "vnc;rdp;remote;desktop;windows;support;access;view"
msgstr "vnc;rdp;аддалены;працоўны;стол;windows;падтрымка;доступ;прагляд"
#: data/org.gnome.Connections.xml:5
msgid "Remote Desktop (VNC) file"
msgstr "Файл (VNC) аддаленага працоўнага стала"
#: src/actions-popover.vala:44
msgid "Delete"
msgstr "Выдаліць"
#: src/actions-popover.vala:48 src/topbar.vala:66 src/ui/topbar.ui:220
msgid "Properties"
msgstr "Уласцівасці"
#: src/application.vala:88
msgid "translator-credits"
msgstr ""
"Ігар Грачышка <ihar.hrachyshka@gmail.com>\n"
"Юрась Шумовіч <shumovichy@gmail.com>"
#: src/application.vala:89 src/application.vala:242
msgid "A remote desktop client for the GNOME desktop environment"
msgstr "Кліент аддаленага працоўнага стала для асяроддзя GNOME"
#: src/application.vala:151
#, c-format
msgid "Couldn’t open file of unknown mime type %s"
msgstr "Не ўдалося адкрыць файл або невядомы MIME-тып %s"
#: src/application.vala:182
#, c-format
msgid "Connection to “%s” has been deleted"
msgstr "Падлучэнне да «%s» выдалена"
#: src/application.vala:185
msgid "Undo"
msgstr "Адрабіць"
#: src/application.vala:232
msgid "URL to connect"
msgstr "URL-адрас падлучэння"
#: src/application.vala:233
msgid "Open .vnc or .rdp file at the given PATH"
msgstr "Адкрыць файл .vnc або .rdp з указанага шляху"
#: src/application.vala:234
msgid "Open in full screen"
msgstr "Перайсці ў поўнаэкранны рэжым"
#: src/application.vala:257
msgid "Too many command-line arguments specified.\n"
msgstr "Указана занадта шмат аргументаў загаднага радка.\n"
#. Translators: %s => the timestamp of when the screenshot was taken.
#: src/connection.vala:70
#, c-format
msgid "Screenshot from %s"
msgstr "Здымак экрана ад %s"
#: src/connection.vala:85
msgid "Screenshot taken"
msgstr "Здымак экрана атрыманы"
#. Translators: Open is a verb
#: src/connection.vala:88
msgid "Open"
msgstr "Адкрыць"
#: src/connection.vala:161
#, c-format
msgid "“%s” requires authentication"
msgstr "«%s» патрабуе праверкі сапраўднасці"
#: src/connection.vala:200
#, c-format
msgid "Authentication failed: %s"
msgstr "Сапраўднасць не пацверджана: %s"
#. Translators: Showing size of widget as WIDTH×HEIGHT here.
#: src/display-view.vala:126
#, c-format
msgid "%d×%d"
msgstr "%d×%d"
#: src/onboarding-dialog.vala:86 src/ui/onboarding-dialog.ui:147
msgid "No Thanks"
msgstr "Дзякуй, не трэба"
#: src/onboarding-dialog.vala:86
msgid "Close"
msgstr "Закрыць"
#: src/topbar.vala:58 src/ui/topbar.ui:212
msgid "Take Screenshot"
msgstr "Зрабіць здымак экрана"
#: src/topbar.vala:62 src/ui/topbar.ui:216
msgid "Fullscreen"
msgstr "На ўвесь экран"
#: src/ui/assistant.ui:26
msgid "Enter the network identifier of the remote desktop to connect to:"
msgstr ""
"Увядзіце сеткавы ідэнтыфікатар аддаленага працоўнага стала, каб падлучыцца:"
#: src/ui/assistant.ui:53
msgid "Connection Type"
msgstr "Тып падлучэння"
#: src/ui/assistant.ui:63
msgid "RDP (standard for connecting to Windows)"
msgstr "RDP (стандартнае падлучэнне для Windows)"
#: src/ui/assistant.ui:72
msgid "VNC (standard for connecting to Linux)"
msgstr "VNC (стандартнае падлучэнне для Linux)"
#: src/ui/assistant.ui:90 src/ui/topbar.ui:201
msgid "Help"
msgstr "Даведка"
#: src/ui/assistant.ui:100
msgid "Connect"
msgstr "Падлучыцца"
#: src/ui/auth-notification.ui:39
msgid "_Username"
msgstr "І_мя карыстальніка"
#: src/ui/auth-notification.ui:71
msgid "_Password"
msgstr "_Пароль"
#: src/ui/auth-notification.ui:108
msgid "Sign In"
msgstr "Увайсці"
#: src/ui/onboarding-dialog.ui:41 src/ui/window.ui:52
msgid "Welcome to Connections"
msgstr "Вітаем у Connections"
#: src/ui/onboarding-dialog.ui:42
msgid "Learn about how Connections works."
msgstr "Даведайцеся як працуе Connections."
#: src/ui/onboarding-dialog.ui:49
msgid "Use other desktops, remotely"
msgstr "Аддаленае карыстанне іншым працоўным сталом"
#: src/ui/onboarding-dialog.ui:50
msgid ""
"Use Connections to view the screen of other desktops. You can control them "
"using the pointer and keyboard, too!"
msgstr ""
"Выкарыстоўвайце Connections, каб праглядзець экран іншага працоўнага стала. "
"А яшчэ можна кіраваць ім з дапамогай мышы і клавіятуры!"
#: src/ui/onboarding-dialog.ui:57
msgid "Connect to different operating systems"
msgstr "Падлучайцеся да розных аперацыйных сістэм"
#: src/ui/onboarding-dialog.ui:58
msgid "Access Linux, Mac, and Windows desktops using Connections."
msgstr "Доступ да камп'ютараў з Linux, Mac і Windows."
#: src/ui/onboarding-dialog.ui:65
msgid "Enable remote desktop before connecting"
msgstr "Перад падлучэннем уключыце аддалены працоўны стол"
#: src/ui/onboarding-dialog.ui:66
msgid ""
"Computers need to be set up for remote desktop before you can connect to "
"them."
msgstr ""
"Трэба наладзіць аддалены працоўны стол на камп'ютары, каб падлучыцца да яго."
#: src/ui/onboarding-dialog.ui:73
msgid "We hope that you enjoy Connections!"
msgstr "Спадзяемся, Connections вас задаволіць!"
#: src/ui/onboarding-dialog.ui:74
msgid "More information can be found in the help."
msgstr "Больш інфармацыі вы можаце знайсці ў даведцы."
#: src/ui/rdp-preferences.ui:9 src/ui/vnc-preferences.ui:9
msgid "Connection preferences"
msgstr "Параметры падлучэння"
#: src/ui/rdp-preferences.ui:22 src/ui/vnc-preferences.ui:22
msgid "Address"
msgstr "Адрас"
#: src/ui/rdp-preferences.ui:37 src/ui/vnc-preferences.ui:37
msgid "Name"
msgstr "Назва"
#: src/ui/rdp-preferences.ui:51 src/ui/vnc-preferences.ui:59
msgid "Scaling"
msgstr "Маштабаванне"
#: src/ui/topbar.ui:21
msgid "New"
msgstr "Новы"
#: src/ui/topbar.ui:42
msgid "Application Menu"
msgstr "Меню праграмы"
#: src/ui/topbar.ui:70
msgid "Search"
msgstr "Пошук"
#: src/ui/topbar.ui:104
msgid "Go Back"
msgstr "Вярнуцца"
#: src/ui/topbar.ui:125
msgid "Display Menu"
msgstr "Меню дысплэя"
#: src/ui/topbar.ui:149
msgid "Disconnect"
msgstr "Адлучыцца"
#: src/ui/topbar.ui:174
msgid "Keyboard shortcuts"
msgstr "Спалучэнні клавіш"
#: src/ui/topbar.ui:197
msgid "Keyboard Shortcuts"
msgstr "Спалучэнні клавіш"
#: src/ui/topbar.ui:205
msgid "About Connections"
msgstr "Пра Connections"
#: src/ui/topbar.ui:234
msgid "Ctrl + Alt + Backspace"
msgstr "Ctrl + Alt + Backspace"
#: src/ui/topbar.ui:241
msgid "Ctrl + Alt + Del"
msgstr "Ctrl + Alt + Del"
#: src/ui/topbar.ui:248
msgid "Ctrl + Alt + F1"
msgstr "Ctrl + Alt + F1"
#: src/ui/topbar.ui:255
msgid "Ctrl + Alt + F2"
msgstr "Ctrl + Alt + F2"
#: src/ui/topbar.ui:262
msgid "Ctrl + Alt + F3"
msgstr "Ctrl + Alt + F3"
#: src/ui/topbar.ui:269
msgid "Ctrl + Alt + F7"
msgstr "Ctrl + Alt + F7"
#: src/ui/vnc-preferences.ui:54
msgid "Display"
msgstr "Дысплэй"
#: src/ui/vnc-preferences.ui:66
msgid "View only"
msgstr "Толькі прагляд"
#: src/ui/vnc-preferences.ui:73
msgid "Show local pointer"
msgstr "Паказваць лакальны ўказальнік"
#: src/ui/vnc-preferences.ui:80
msgid "Enable audio"
msgstr "Уключыць гук"
#: src/ui/vnc-preferences.ui:88
msgid "Bandwidth"
msgstr "Паласа прапускання"
#: src/ui/vnc-preferences.ui:95
msgid "High quality"
msgstr "Высокая якасць"
#: src/ui/vnc-preferences.ui:96
msgid "Fast refresh"
msgstr "Хуткае абнаўленне"
#: src/ui/vnc-preferences.ui:107
msgid "Scale mode"
msgstr "Маштабаванне"
#: src/ui/vnc-preferences.ui:114
msgid "Fit window"
msgstr "Умясціць у акно"
#: src/ui/vnc-preferences.ui:115
msgid "Original size"
msgstr "Зыходны памер"
#: src/ui/window.ui:53
msgid "Just hit the <b>+</b> button to make your first connection."
msgstr "Проста націсніце на кнопку <b>+</b>, каб стварыць першае падлучэнне."
#: src/vnc-connection.vala:149
msgid "Couldn’t parse the file"
msgstr "Не ўдалося разабраць файл"
#. Translators: %s is a VNC file key
#: src/vnc-connection.vala:157 src/vnc-connection.vala:162
#: src/vnc-connection.vala:167 src/vnc-connection.vala:172
#, c-format
msgid "VNC File is missing key “%s”"
msgstr "У файле VNC адсутнічае ключ «%s»"
......@@ -7,17 +7,17 @@ msgid ""
msgstr ""
"Project-Id-Version: gnome-connections master\n"
"Report-Msgid-Bugs-To: https://gitlab.gnome.org/GNOME/connections/issues\n"
"POT-Creation-Date: 2021-11-06 21:25+0000\n"
"PO-Revision-Date: 2021-11-14 22:13+0300\n"
"Last-Translator: Alexey Rubtsov <rushills@gmail.com>\n"
"POT-Creation-Date: 2022-09-19 13:12+0000\n"
"PO-Revision-Date: 2022-09-20 14:24+0300\n"
"Last-Translator: Aleksandr Melman <Alexmelman88@gmail.com>\n"
"Language-Team: Russian <gnome-cyr@gnome.org>\n"
"Language: ru\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=3; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n"
"%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);\n"
"X-Generator: Poedit 3.0\n"
"Plural-Forms: nplurals=3; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && "
"n%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);\n"
"X-Generator: Poedit 3.1\n"
#: data/org.gnome.Connections.appdata.xml.in:7
#: data/org.gnome.Connections.desktop.in:3 src/application.vala:92
......@@ -58,9 +58,9 @@ msgstr ""
"Подключения использует широко поддерживаемые протоколы VNC и RDP, и один из "
"них должен быть включен на рабочем столе, к которому вы хотите подключиться."
#: data/org.gnome.Connections.appdata.xml.in:34
#: data/org.gnome.Connections.appdata.xml.in:43
msgid "The GNOME Project"
msgstr "Проект GNOME"
msgstr "The GNOME Project"
#: data/org.gnome.Connections.desktop.in:8
msgid "vnc;rdp;remote;desktop;windows;support;access;view"
......@@ -86,7 +86,7 @@ msgstr ""
"Alexey Rubtsov <rushills@gmail.com>, 2021\n"
"Aleksandr Melman <Alexmelman88@gmail.com>, 2021"
#: src/application.vala:89 src/application.vala:240
#: src/application.vala:89 src/application.vala:242
msgid "A remote desktop client for the GNOME desktop environment"
msgstr "Клиент удаленного рабочего стола для среды рабочего стола GNOME"
......@@ -95,52 +95,52 @@ msgstr "Клиент удаленного рабочего стола для с
msgid "Couldn’t open file of unknown mime type %s"
msgstr "Не удалось открыть файл неизвестного mime-типа %s"
#: src/application.vala:180
#: src/application.vala:182
#, c-format
msgid "Connection to “%s” has been deleted"
msgstr "Соединение с «%s» было удалено"
#: src/application.vala:183
#: src/application.vala:185
msgid "Undo"
msgstr "Отменить"
#: src/application.vala:230
#: src/application.vala:232
msgid "URL to connect"
msgstr "URL для подключения"
#: src/application.vala:231
#: src/application.vala:233
msgid "Open .vnc or .rdp file at the given PATH"
msgstr "Открыть файл .vnc или .rdp в указанном Пути"
#: src/application.vala:232
#: src/application.vala:234
msgid "Open in full screen"
msgstr "Полноэкранный режим"
msgstr "Открыть в полноэкранном режиме"
#: src/application.vala:255
#: src/application.vala:257
msgid "Too many command-line arguments specified.\n"
msgstr "Указано слишком много аргументов командной строки.\n"
#. Translators: %s => the timestamp of when the screenshot was taken.
#: src/connection.vala:64
#: src/connection.vala:70
#, c-format
msgid "Screenshot from %s"
msgstr "Снимок экрана от %s"
#: src/connection.vala:79
#: src/connection.vala:85
msgid "Screenshot taken"
msgstr "Сделан скриншот"
msgstr "Сделан снимок экрана"
#. Translators: Open is a verb
#: src/connection.vala:82
#: src/connection.vala:88
msgid "Open"
msgstr "Открыть"
#: src/connection.vala:127
#: src/connection.vala:161
#, c-format
msgid "“%s” requires authentication"
msgstr "«%s» требует аутентификации"
#: src/connection.vala:146
#: src/connection.vala:200
#, c-format
msgid "Authentication failed: %s"
msgstr "Аутентификация не прошла: %s"
......@@ -161,7 +161,7 @@ msgstr "Закрыть"
#: src/topbar.vala:58 src/ui/topbar.ui:212
msgid "Take Screenshot"
msgstr "Сделать скриншот"
msgstr "Сделать снимок экрана"
#: src/topbar.vala:62 src/ui/topbar.ui:216
msgid "Fullscreen"
......@@ -251,23 +251,27 @@ msgstr "Мы надеемся, что Подключения вам понрав
#: src/ui/onboarding-dialog.ui:74
msgid "More information can be found in the help."
msgstr "Вы сможете найти подробную информацию в Справке"
msgstr "Вы сможете найти подробную информацию в справке."
#: src/ui/rdp-preferences.ui:9 src/ui/vnc-preferences.ui:9
msgid "Connection preferences"
msgstr "Настройки подключения"
#: src/ui/rdp-preferences.ui:23 src/ui/vnc-preferences.ui:23
#: src/ui/rdp-preferences.ui:22 src/ui/vnc-preferences.ui:22
msgid "Address"
msgstr "Адрес"
#: src/ui/rdp-preferences.ui:38 src/ui/vnc-preferences.ui:38
#: src/ui/rdp-preferences.ui:37 src/ui/vnc-preferences.ui:37
msgid "Name"
msgstr "Имя"
#: src/ui/rdp-preferences.ui:51 src/ui/vnc-preferences.ui:59
msgid "Scaling"
msgstr "Масштабирование"
#: src/ui/topbar.ui:21
msgid "New"
msgstr "Новый"
msgstr "Новое"
#: src/ui/topbar.ui:42
msgid "Application Menu"
......@@ -283,7 +287,7 @@ msgstr "Назад"
#: src/ui/topbar.ui:125
msgid "Display Menu"
msgstr "Отображение меню"
msgstr "Меню дисплея"
#: src/ui/topbar.ui:149
msgid "Disconnect"
......@@ -325,47 +329,43 @@ msgstr "Ctrl + Alt + F3"
msgid "Ctrl + Alt + F7"
msgstr "Ctrl + Alt + F7"
#: src/ui/vnc-preferences.ui:55
#: src/ui/vnc-preferences.ui:54
msgid "Display"
msgstr "Дисплей"
#: src/ui/vnc-preferences.ui:60
msgid "Scaling"
msgstr "Масштабирование"
#: src/ui/vnc-preferences.ui:67
#: src/ui/vnc-preferences.ui:66
msgid "View only"
msgstr "Только просмотр"
#: src/ui/vnc-preferences.ui:74
#: src/ui/vnc-preferences.ui:73
msgid "Show local pointer"
msgstr "Показать локальный указатель"
#: src/ui/vnc-preferences.ui:81
#: src/ui/vnc-preferences.ui:80
msgid "Enable audio"
msgstr "Включить звук"
#: src/ui/vnc-preferences.ui:89
#: src/ui/vnc-preferences.ui:88
msgid "Bandwidth"
msgstr "Полоса пропускания"
#: src/ui/vnc-preferences.ui:96
#: src/ui/vnc-preferences.ui:95
msgid "High quality"
msgstr "Высокое качество"
#: src/ui/vnc-preferences.ui:97
#: src/ui/vnc-preferences.ui:96
msgid "Fast refresh"
msgstr "Быстрое обновление"
#: src/ui/vnc-preferences.ui:108
#: src/ui/vnc-preferences.ui:107
msgid "Scale mode"
msgstr "Режим масштабирования"
#: src/ui/vnc-preferences.ui:115
#: src/ui/vnc-preferences.ui:114
msgid "Fit window"
msgstr "Подходящее окно"
#: src/ui/vnc-preferences.ui:116
#: src/ui/vnc-preferences.ui:115
msgid "Original size"
msgstr "Исходный размер"
......
......@@ -29,6 +29,11 @@ namespace Connections {
[GtkChild]
public unowned Gtk.Image thumbnail;
private string default_thumbnail_icon {
owned get {
return ("%s-symbolic").printf (Application.application.application_id);
}
}
private uint thumbnail_id = 0;
......@@ -38,6 +43,7 @@ namespace Connections {
update_display_name ();
connection.notify["display-name"].connect (update_display_name);
thumbnail.icon_name = default_thumbnail_icon;
connection.show.connect (update_thumbnail);
}
......@@ -50,7 +56,7 @@ namespace Connections {
thumbnail_id = 0;
if (!connection.connected) {
thumbnail.set_from_icon_name ("org.gnome.Connections-symbolic",
thumbnail.set_from_icon_name (default_thumbnail_icon,
Gtk.IconSize.LARGE_TOOLBAR);
return Source.REMOVE;
}
......
......@@ -104,23 +104,8 @@ namespace Connections {
if (event.type == EventType.GRAB_BROKEN)
return false;
if (event_box.get_child () != null) {
var child = event_box.get_child ();
var offset_x = (get_allocated_width () - child.get_allocated_width ()) / 2.0;
var offset_y = (get_allocated_height () - child.get_allocated_height ()) / 2.0;
switch (event.get_event_type ()) {
case Gdk.EventType.MOTION_NOTIFY:
event.motion.x -= offset_x;
event.motion.y -= offset_y;
break;
default:
break;
}
child.event (event);
}
if (event_box.get_child () != null)
event_box.get_child ().event (event);
return false;
}
......
......@@ -35,7 +35,7 @@ connections_deps = [
dependency ('libsecret-1'),
]
gtk_frdp_dep = dependency('gtk-frdp-0.1', required: false)
gtk_frdp_dep = dependency('gtk-frdp-0.2', required: false)
if gtk_frdp_dep.found()
connections_deps += gtk_frdp_dep
......
......@@ -63,6 +63,8 @@ namespace Connections {
}
public override int port { get; protected set; default = 3389; }
public bool resize_supported { get; protected set; default = false; }
public string scale_mode { get; set; default = "fit-window"; }
construct {
display = new FrdpDisplay ();
......@@ -74,7 +76,10 @@ namespace Connections {
display.rdp_connected.connect (on_rdp_connection_connected_cb);
//display.rdp_needs_authentication.connect (on_rdp_auth_credential_cb);
display.rdp_auth_failure.connect (auth_failed);
//display.size_allocate.connect (scale);
display.size_allocate.connect (scale);
notify["scale-mode"].connect (scale);
display.notify["resize-supported"].connect (update_resize_supported);
need_username = need_password = true;
}
......@@ -144,6 +149,43 @@ namespace Connections {
display.grab_focus ();
show ();
}
public void scale () {
if (!display.is_open ())
return;
display.scaling = display.expand = false;
switch (scale_mode) {
case "resize-desktop":
resize_desktop_to_window ();
break;
case "fit-window":
scale_to_fit_window ();
break;
case "original":
scale_to_original_size ();
break;
}
}
private void resize_desktop_to_window () {
display.allow_resize = true;
}
private void scale_to_fit_window () {
display.scaling = display.hexpand = true;
display.width_request = display.height_request = 0;
display.allow_resize = false;
}
private void scale_to_original_size () {
display.allow_resize = false;
}
private void update_resize_supported () {
resize_supported = display.resize_supported;
}
}
private class FrdpDisplay : Frdp.Display {
......
......@@ -27,14 +27,47 @@ namespace Connections {
[GtkChild]
private unowned Gtk.Label host_address_label;
[GtkChild]
private unowned BooleanProperty scaling;
private unowned Gtk.ComboBoxText scale_mode_combo;
public RdpPreferencesWindow (Connection connection) {
this.connection = connection;
update_scale_mode_combo ();
bind_widget_property (connection_name_entry, "text", "display_name");
bind_widget_property (host_address_label, "label", "uri");
bind_widget_property (scaling, "active", "scaling");
bind_widget_property (scale_mode_combo, "active_id", "scale-mode");
connection.notify["resize-supported"].connect (update_scale_mode_combo);
}
private void update_scale_mode_combo () {
if ((((RdpConnection) connection).resize_supported ||
((RdpConnection) connection).scale_mode == "resize-desktop") &&
!combo_contains_item (scale_mode_combo, "resize-desktop")) {
// Translators: Combo item for resizing remote desktop to window's size
scale_mode_combo.insert (0, "resize-desktop", _("Resize desktop"));
}
}
private bool combo_contains_item (Gtk.ComboBoxText combo_box, string item_id) {
Gtk.TreeIter iter;
string mode;
if (scale_mode_combo.model.get_iter_first (out iter)) {
scale_mode_combo.model.get (iter, 1, out mode);
if (mode == item_id) {
return true;
} else {
while (scale_mode_combo.model.iter_next (ref iter)) {
scale_mode_combo.model.get (iter, 1, out mode);
if (mode == item_id)
return true;
}
}
}
return false;
}
}
}
......@@ -8,7 +8,6 @@
<child>
<object class="GtkImage" id="thumbnail">
<property name="visible">True</property>
<property name="icon-name">org.gnome.Connections-symbolic</property>
<property name="pixel-size">24</property>
<property name="halign">fill</property>
<property name="margin">10</property>
......
......@@ -46,9 +46,13 @@
</child>
<child>
<object class="ConnectionsBooleanProperty" id="scaling">
<object class="GtkComboBoxText" id="scale_mode_combo">
<property name="visible">True</property>
<property name="title" translatable="yes">Scaling</property>
<property name="valign">center</property>
<items>
<item id="fit-window" translatable="yes">Fit window</item>
<item id="original" translatable="yes">Original size</item>
</items>
</object>
</child>
</object>
......
......@@ -53,13 +53,6 @@
<property name="visible">True</property>
<property name="title" translatable="yes">Display</property>
<child>
<object class="ConnectionsBooleanProperty" id="scaling">
<property name="visible">True</property>
<property name="title" translatable="yes">Scaling</property>
</object>
</child>
<child>
<object class="ConnectionsBooleanProperty" id="view_only">
<property name="visible">True</property>
......@@ -111,6 +104,7 @@
<property name="visible">True</property>
<property name="valign">center</property>
<items>
<item id="resize-desktop" translatable="yes">Resize desktop</item>
<item id="fit-window" translatable="yes">Fit window</item>
<item id="original" translatable="yes">Original size</item>
</items>
......
......@@ -48,7 +48,6 @@
<child>
<object class="HdyStatusPage" id="empty_view">
<property name="visible">True</property>
<property name="icon-name">org.gnome.Connections-symbolic</property>
<property name="title" translatable="yes">Welcome to Connections</property>
<property name="description" translatable="yes">Just hit the &lt;b&gt;+&lt;/b&gt; button to make your first connection.</property>
</object>
......
......@@ -106,6 +106,7 @@ namespace Connections {
display.set_keyboard_grab (true);
display.set_pointer_grab (true);
display.set_force_size (false);
display.set_keep_aspect_ratio (true);
dispose_display ();
......@@ -273,20 +274,33 @@ namespace Connections {
display.scaling = display.expand = false;
if (scale_mode == "original")
scale_to_original_size ();
else
scale_to_fit_window ();
switch (scale_mode) {
case "resize-desktop":
resize_desktop_to_window ();
break;
case "fit-window":
scale_to_fit_window ();
break;
case "original":
scale_to_original_size ();
break;
}
}
private void resize_desktop_to_window () {
display.set_allow_resize (true);
}
private void scale_to_fit_window () {
display.scaling = display.hexpand = true;
display.width_request = display.height_request = 0;
display.set_allow_resize (false);
}
private void scale_to_original_size () {
display.width_request = display.width;
display.height_request = display.height;
display.set_allow_resize (false);
}
}
}