mirror of
https://gitlab.linphone.org/BC/public/linphone-desktop.git
synced 2026-05-07 14:44:01 +00:00
Deactivate account creation and login by phone because of unsecure captcha.
This commit is contained in:
parent
d969216e73
commit
8257847f39
4 changed files with 22 additions and 6 deletions
|
|
@ -20,7 +20,6 @@ update_presence_model_timestamp_before_publish_expires_refresh=1
|
|||
max_conference_size=vga
|
||||
|
||||
[ui]
|
||||
|
||||
use_qrcode=0
|
||||
|
||||
[account_creator]
|
||||
|
|
|
|||
|
|
@ -237,12 +237,14 @@ void SettingsModel::setAutoApplyProvisioningConfigUriHandlerEnabled (bool status
|
|||
// ---------------------------------------------------------------------------
|
||||
|
||||
bool SettingsModel::getAssistantSupportsPhoneNumbers () const {
|
||||
return !!mConfig->getInt(UiSection, "assistant_supports_phone_numbers", 1);
|
||||
return !!mConfig->getInt(UiSection, getEntryFullName(UiSection, "assistant_supports_phone_numbers") , 1);
|
||||
}
|
||||
|
||||
void SettingsModel::setAssistantSupportsPhoneNumbers (bool status) {
|
||||
mConfig->setInt(UiSection, "assistant_supports_phone_numbers", status);
|
||||
emit assistantSupportsPhoneNumbersChanged(status);
|
||||
if(!isReadOnly(UiSection, "assistant_supports_phone_numbers")) {
|
||||
mConfig->setInt(UiSection, "assistant_supports_phone_numbers", status);
|
||||
emit assistantSupportsPhoneNumbersChanged(status);
|
||||
}
|
||||
}
|
||||
|
||||
bool SettingsModel::useWebview() const{
|
||||
|
|
|
|||
|
|
@ -118,12 +118,24 @@ ColumnLayout {
|
|||
onClicked:{ assistant.pushView($view, $props) }
|
||||
}
|
||||
}
|
||||
|
||||
Connections{
|
||||
target: SettingsModel
|
||||
onAssistantSupportsPhoneNumbersChanged: {
|
||||
if(!SettingsModel.useWebview()){
|
||||
buttonsModel.get(0).$view = !SettingsModel.assistantSupportsPhoneNumbers ? 'CreateAppSipAccountWithEmail' : 'CreateAppSipAccount'
|
||||
}
|
||||
}
|
||||
}
|
||||
model: ListModel {
|
||||
id: buttonsModel
|
||||
Component.onCompleted: {
|
||||
insert(0, {
|
||||
$text: qsTr('createAppSipAccount'),
|
||||
$view: SettingsModel.useWebview() ? 'CreateAppSipAccountWithWebView' : 'CreateAppSipAccount',
|
||||
$view: SettingsModel.useWebview()
|
||||
? 'CreateAppSipAccountWithWebView'
|
||||
: !SettingsModel.assistantSupportsPhoneNumbers
|
||||
? 'CreateAppSipAccountWithEmail'
|
||||
: 'CreateAppSipAccount',
|
||||
$viewType: 'CreateAppSipAccount',
|
||||
$props: SettingsModel.useWebview() ? {defaultUrl: SettingsModel.assistantRegistrationUrl, defaultLogoutUrl:SettingsModel.assistantLogoutUrl, configFilename: 'create-app-sip-account.rc'}
|
||||
: {}
|
||||
|
|
|
|||
|
|
@ -1,6 +1,8 @@
|
|||
import QtQuick 2.7
|
||||
|
||||
import Common 1.0
|
||||
import ConstantsCpp 1.0
|
||||
import Linphone 1.0
|
||||
|
||||
import App.Styles 1.0
|
||||
|
||||
|
|
@ -22,6 +24,7 @@ import App.Styles 1.0
|
|||
width: CreateAppSipAccountStyle.buttons.button.width
|
||||
|
||||
TextButtonA {
|
||||
visible: SettingsModel.assistantSupportsPhoneNumbers
|
||||
text: qsTr('withPhoneNumber')
|
||||
|
||||
height: CreateAppSipAccountStyle.buttons.button.height
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue