mirror of
https://github.com/amnezia-vpn/amnezia-client.git
synced 2026-06-23 02:00:20 +07:00
Icon for macos and tiny fixes
This commit is contained in:
@@ -214,7 +214,11 @@ if(APPLE)
|
|||||||
|
|
||||||
set(CMAKE_OSX_DEPLOYMENT_TARGET 10.15)
|
set(CMAKE_OSX_DEPLOYMENT_TARGET 10.15)
|
||||||
add_compile_definitions(MVPN_MACOS)
|
add_compile_definitions(MVPN_MACOS)
|
||||||
# ICON = $$PWD/images/app.icns
|
|
||||||
|
set(ICON_FILE ${CMAKE_CURRENT_SOURCE_DIR}/images/app.icns)
|
||||||
|
set(MACOSX_BUNDLE_ICON_FILE app.icns)
|
||||||
|
set_source_files_properties(${ICON_FILE} PROPERTIES MACOSX_PACKAGE_LOCATION Resources)
|
||||||
|
set(SOURCES ${SOURCES} ${ICON_FILE})
|
||||||
|
|
||||||
find_library(FW_COCOA Cocoa)
|
find_library(FW_COCOA Cocoa)
|
||||||
find_library(FW_APPLICATIONSERVICES ApplicationServices)
|
find_library(FW_APPLICATIONSERVICES ApplicationServices)
|
||||||
|
|||||||
@@ -23,7 +23,7 @@ class StartPageLogic : public PageLogicBase
|
|||||||
AUTO_PROPERTY(QString, labelWaitInfoText)
|
AUTO_PROPERTY(QString, labelWaitInfoText)
|
||||||
AUTO_PROPERTY(bool, pushButtonBackFromStartVisible)
|
AUTO_PROPERTY(bool, pushButtonBackFromStartVisible)
|
||||||
|
|
||||||
AUTO_PROPERTY(QString, privateKeyPassphrase);
|
AUTO_PROPERTY(QString, privateKeyPassphrase)
|
||||||
|
|
||||||
READONLY_PROPERTY(QRegularExpression, ipAddressPortRegex)
|
READONLY_PROPERTY(QRegularExpression, ipAddressPortRegex)
|
||||||
public:
|
public:
|
||||||
|
|||||||
@@ -233,9 +233,8 @@ PageBase {
|
|||||||
anchors.top: label_server_ip.bottom
|
anchors.top: label_server_ip.bottom
|
||||||
anchors.horizontalCenter: parent.horizontalCenter
|
anchors.horizontalCenter: parent.horizontalCenter
|
||||||
text: StartPageLogic.lineEditIpText
|
text: StartPageLogic.lineEditIpText
|
||||||
onEditingFinished: {
|
onEditingFinished: { StartPageLogic.lineEditIpText = text }
|
||||||
StartPageLogic.lineEditIpText = text
|
onTextEdited: { StartPageLogic.lineEditIpText = text }
|
||||||
}
|
|
||||||
|
|
||||||
validator: RegularExpressionValidator {
|
validator: RegularExpressionValidator {
|
||||||
regularExpression: StartPageLogic.ipAddressPortRegex
|
regularExpression: StartPageLogic.ipAddressPortRegex
|
||||||
@@ -253,9 +252,8 @@ PageBase {
|
|||||||
anchors.top: label_login.bottom
|
anchors.top: label_login.bottom
|
||||||
anchors.horizontalCenter: parent.horizontalCenter
|
anchors.horizontalCenter: parent.horizontalCenter
|
||||||
text: StartPageLogic.lineEditLoginText
|
text: StartPageLogic.lineEditLoginText
|
||||||
onEditingFinished: {
|
onEditingFinished: { StartPageLogic.lineEditLoginText = text }
|
||||||
StartPageLogic.lineEditLoginText = text
|
onTextEdited: { StartPageLogic.lineEditLoginText = text }
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
LabelType {
|
LabelType {
|
||||||
@@ -268,25 +266,29 @@ PageBase {
|
|||||||
id: new_server_password
|
id: new_server_password
|
||||||
anchors.top: label_new_server_password.bottom
|
anchors.top: label_new_server_password.bottom
|
||||||
anchors.horizontalCenter: parent.horizontalCenter
|
anchors.horizontalCenter: parent.horizontalCenter
|
||||||
|
|
||||||
|
inputMethodHints: Qt.ImhSensitiveData
|
||||||
echoMode: TextInput.Password
|
echoMode: TextInput.Password
|
||||||
text: StartPageLogic.lineEditPasswordText
|
text: StartPageLogic.lineEditPasswordText
|
||||||
onEditingFinished: {
|
onEditingFinished: { StartPageLogic.lineEditPasswordText = text }
|
||||||
StartPageLogic.lineEditPasswordText = text
|
onTextEdited: { StartPageLogic.lineEditPasswordText = text }
|
||||||
}
|
onAccepted: { StartPageLogic.onPushButtonConnect() }
|
||||||
}
|
}
|
||||||
TextFieldType {
|
TextFieldType {
|
||||||
id: new_server_ssh_key
|
id: new_server_ssh_key
|
||||||
anchors.top: label_new_server_password.bottom
|
anchors.top: label_new_server_password.bottom
|
||||||
anchors.horizontalCenter: parent.horizontalCenter
|
anchors.horizontalCenter: parent.horizontalCenter
|
||||||
|
|
||||||
|
visible: false
|
||||||
height: 71
|
height: 71
|
||||||
font.pixelSize: 10
|
font.pixelSize: 10
|
||||||
verticalAlignment: Text.AlignTop
|
verticalAlignment: Text.AlignTop
|
||||||
|
inputMethodHints: Qt.ImhSensitiveData
|
||||||
|
|
||||||
text: StartPageLogic.textEditSshKeyText
|
text: StartPageLogic.textEditSshKeyText
|
||||||
onEditingFinished: {
|
onEditingFinished: { StartPageLogic.textEditSshKeyText = text }
|
||||||
StartPageLogic.textEditSshKeyText = text
|
onTextEdited: { StartPageLogic.textEditSshKeyText = text }
|
||||||
}
|
onAccepted: { StartPageLogic.onPushButtonConnect() }
|
||||||
visible: false
|
|
||||||
}
|
}
|
||||||
|
|
||||||
LabelType {
|
LabelType {
|
||||||
|
|||||||
@@ -354,7 +354,7 @@ Window {
|
|||||||
}
|
}
|
||||||
textArea.wrapMode: cbLogWrap.checked ? TextEdit.WordWrap: TextEdit.NoWrap
|
textArea.wrapMode: cbLogWrap.checked ? TextEdit.WordWrap: TextEdit.NoWrap
|
||||||
|
|
||||||
Keys.onPressed: {
|
Keys.onPressed: function(event) {
|
||||||
UiLogic.keyPressEvent(event.key)
|
UiLogic.keyPressEvent(event.key)
|
||||||
event.accepted = true
|
event.accepted = true
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user