mirror of
https://gitlab.linphone.org/BC/public/linphone-desktop.git
synced 2026-04-17 20:08:28 +00:00
clean code to remove warning
This commit is contained in:
parent
4fca033943
commit
858ec41ccb
12 changed files with 25 additions and 35 deletions
|
|
@ -297,12 +297,6 @@ App::App(int &argc, char *argv[])
|
||||||
QCoreApplication::setApplicationName(EXECUTABLE_NAME);
|
QCoreApplication::setApplicationName(EXECUTABLE_NAME);
|
||||||
QApplication::setOrganizationDomain(EXECUTABLE_NAME);
|
QApplication::setOrganizationDomain(EXECUTABLE_NAME);
|
||||||
QCoreApplication::setApplicationVersion(APPLICATION_SEMVER);
|
QCoreApplication::setApplicationVersion(APPLICATION_SEMVER);
|
||||||
// CarshReporter must be call after app initialization like names.
|
|
||||||
#ifdef HAVE_CRASH_HANDLER
|
|
||||||
CrashReporter::start();
|
|
||||||
#else
|
|
||||||
lWarning() << "[Main] The application doesn't support the CrashReporter.";
|
|
||||||
#endif
|
|
||||||
|
|
||||||
// If not OpenGL, createRender is never call.
|
// If not OpenGL, createRender is never call.
|
||||||
QQuickWindow::setGraphicsApi(QSGRendererInterface::OpenGL);
|
QQuickWindow::setGraphicsApi(QSGRendererInterface::OpenGL);
|
||||||
|
|
|
||||||
|
|
@ -31,7 +31,6 @@ class ListProxy : public AbstractListProxy<QSharedPointer<QObject>> {
|
||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
|
||||||
public:
|
public:
|
||||||
Q_PROPERTY(int count READ getCount NOTIFY countChanged)
|
|
||||||
ListProxy(QObject *parent = Q_NULLPTR);
|
ListProxy(QObject *parent = Q_NULLPTR);
|
||||||
virtual ~ListProxy();
|
virtual ~ListProxy();
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -570,8 +570,8 @@ void SettingsCore::setSelf(QSharedPointer<SettingsCore> me) {
|
||||||
disableChatFeature, DisableChatFeature)
|
disableChatFeature, DisableChatFeature)
|
||||||
DEFINE_CORE_GETSET_CONNECT(mSettingsModelConnection, SettingsCore, SettingsModel, settingsModel, bool,
|
DEFINE_CORE_GETSET_CONNECT(mSettingsModelConnection, SettingsCore, SettingsModel, settingsModel, bool,
|
||||||
disableMeetingsFeature, DisableMeetingsFeature)
|
disableMeetingsFeature, DisableMeetingsFeature)
|
||||||
DEFINE_CORE_GETSET_CONNECT(mSettingsModelConnection, SettingsCore, SettingsModel, settingsModel, bool,
|
DEFINE_CORE_GET_CONNECT(mSettingsModelConnection, SettingsCore, SettingsModel, settingsModel, bool,
|
||||||
showPastMeetings, ShowPastMeetings)
|
showPastMeetings, ShowPastMeetings)
|
||||||
DEFINE_CORE_GETSET_CONNECT(mSettingsModelConnection, SettingsCore, SettingsModel, settingsModel, bool,
|
DEFINE_CORE_GETSET_CONNECT(mSettingsModelConnection, SettingsCore, SettingsModel, settingsModel, bool,
|
||||||
disableBroadcastFeature, DisableBroadcastFeature)
|
disableBroadcastFeature, DisableBroadcastFeature)
|
||||||
DEFINE_CORE_GETSET_CONNECT(mSettingsModelConnection, SettingsCore, SettingsModel, settingsModel, bool,
|
DEFINE_CORE_GETSET_CONNECT(mSettingsModelConnection, SettingsCore, SettingsModel, settingsModel, bool,
|
||||||
|
|
@ -580,8 +580,8 @@ void SettingsCore::setSelf(QSharedPointer<SettingsCore> me) {
|
||||||
HideSettings)
|
HideSettings)
|
||||||
DEFINE_CORE_GETSET_CONNECT(mSettingsModelConnection, SettingsCore, SettingsModel, settingsModel, bool,
|
DEFINE_CORE_GETSET_CONNECT(mSettingsModelConnection, SettingsCore, SettingsModel, settingsModel, bool,
|
||||||
hideAccountSettings, HideAccountSettings)
|
hideAccountSettings, HideAccountSettings)
|
||||||
DEFINE_CORE_GETSET_CONNECT(mSettingsModelConnection, SettingsCore, SettingsModel, settingsModel, bool, hideFps,
|
DEFINE_CORE_GET_CONNECT(mSettingsModelConnection, SettingsCore, SettingsModel, settingsModel, bool, hideFps,
|
||||||
HideFps)
|
HideFps)
|
||||||
DEFINE_CORE_GETSET_CONNECT(mSettingsModelConnection, SettingsCore, SettingsModel, settingsModel, bool,
|
DEFINE_CORE_GETSET_CONNECT(mSettingsModelConnection, SettingsCore, SettingsModel, settingsModel, bool,
|
||||||
disableCallRecordings, DisableCallRecordings)
|
disableCallRecordings, DisableCallRecordings)
|
||||||
DEFINE_CORE_GETSET_CONNECT(mSettingsModelConnection, SettingsCore, SettingsModel, settingsModel, bool,
|
DEFINE_CORE_GETSET_CONNECT(mSettingsModelConnection, SettingsCore, SettingsModel, settingsModel, bool,
|
||||||
|
|
@ -605,16 +605,16 @@ void SettingsCore::setSelf(QSharedPointer<SettingsCore> me) {
|
||||||
assistantThirdPartySipAccountDomain, AssistantThirdPartySipAccountDomain)
|
assistantThirdPartySipAccountDomain, AssistantThirdPartySipAccountDomain)
|
||||||
DEFINE_CORE_GETSET_CONNECT(mSettingsModelConnection, SettingsCore, SettingsModel, settingsModel, QString,
|
DEFINE_CORE_GETSET_CONNECT(mSettingsModelConnection, SettingsCore, SettingsModel, settingsModel, QString,
|
||||||
assistantThirdPartySipAccountTransport, AssistantThirdPartySipAccountTransport)
|
assistantThirdPartySipAccountTransport, AssistantThirdPartySipAccountTransport)
|
||||||
DEFINE_CORE_GETSET_CONNECT(mSettingsModelConnection, SettingsCore, SettingsModel, settingsModel, bool, autoStart,
|
DEFINE_CORE_GET_CONNECT(mSettingsModelConnection, SettingsCore, SettingsModel, settingsModel, bool, autoStart,
|
||||||
AutoStart)
|
AutoStart)
|
||||||
DEFINE_CORE_GETSET_CONNECT(mSettingsModelConnection, SettingsCore, SettingsModel, settingsModel, bool, exitOnClose,
|
DEFINE_CORE_GETSET_CONNECT(mSettingsModelConnection, SettingsCore, SettingsModel, settingsModel, bool, exitOnClose,
|
||||||
ExitOnClose)
|
ExitOnClose)
|
||||||
DEFINE_CORE_GETSET_CONNECT(mSettingsModelConnection, SettingsCore, SettingsModel, settingsModel, bool,
|
DEFINE_CORE_GETSET_CONNECT(mSettingsModelConnection, SettingsCore, SettingsModel, settingsModel, bool,
|
||||||
syncLdapContacts, SyncLdapContacts)
|
syncLdapContacts, SyncLdapContacts)
|
||||||
DEFINE_CORE_GETSET_CONNECT(mSettingsModelConnection, SettingsCore, SettingsModel, settingsModel, QString,
|
DEFINE_CORE_GETSET_CONNECT(mSettingsModelConnection, SettingsCore, SettingsModel, settingsModel, QString,
|
||||||
configLocale, ConfigLocale)
|
configLocale, ConfigLocale)
|
||||||
DEFINE_CORE_GETSET_CONNECT(mSettingsModelConnection, SettingsCore, SettingsModel, settingsModel, QString,
|
DEFINE_CORE_GET_CONNECT(mSettingsModelConnection, SettingsCore, SettingsModel, settingsModel, QString,
|
||||||
downloadFolder, DownloadFolder)
|
downloadFolder, DownloadFolder)
|
||||||
DEFINE_CORE_GET_CONNECT(mSettingsModelConnection, SettingsCore, SettingsModel, settingsModel, int, shortcutCount,
|
DEFINE_CORE_GET_CONNECT(mSettingsModelConnection, SettingsCore, SettingsModel, settingsModel, int, shortcutCount,
|
||||||
ShortcutCount)
|
ShortcutCount)
|
||||||
DEFINE_CORE_GET_CONNECT(mSettingsModelConnection, SettingsCore, SettingsModel, settingsModel, QVariantList,
|
DEFINE_CORE_GET_CONNECT(mSettingsModelConnection, SettingsCore, SettingsModel, settingsModel, QVariantList,
|
||||||
|
|
|
||||||
|
|
@ -14,7 +14,7 @@ Button {
|
||||||
color: style?.color?.normal || DefaultStyle.grey_500
|
color: style?.color?.normal || DefaultStyle.grey_500
|
||||||
pressedColor: checkedIconUrl ? color : style?.color?.pressed || DefaultStyle.grey_500
|
pressedColor: checkedIconUrl ? color : style?.color?.pressed || DefaultStyle.grey_500
|
||||||
hoveredColor: checked ? Qt.darker(pressedColor, 1.05) : style?.color?.hovered || DefaultStyle.grey_500
|
hoveredColor: checked ? Qt.darker(pressedColor, 1.05) : style?.color?.hovered || DefaultStyle.grey_500
|
||||||
property color backgroundColor: hovered
|
backgroundColor: hovered
|
||||||
? hoveredColor
|
? hoveredColor
|
||||||
: checked
|
: checked
|
||||||
? pressedColor
|
? pressedColor
|
||||||
|
|
|
||||||
|
|
@ -8,9 +8,9 @@ import "qrc:/qt/qml/Linphone/view/Style/buttonStyle.js" as ButtonStyle
|
||||||
Button {
|
Button {
|
||||||
id: mainItem
|
id: mainItem
|
||||||
property alias popup: popup
|
property alias popup: popup
|
||||||
property bool shadowEnabled: mainItem.activeFocus && !keyboardFocus || hovered
|
shadowEnabled: mainItem.activeFocus && !keyboardFocus || hovered
|
||||||
property alias popupBackgroundColor: popupBackground.color
|
property alias popupBackgroundColor: popupBackground.color
|
||||||
property color backgroundColor: checked ? pressedColor : hovered || mainItem.activeFocus ? hoveredColor : color
|
backgroundColor: checked ? pressedColor : hovered || mainItem.activeFocus ? hoveredColor : color
|
||||||
property string popUpTitle: ""
|
property string popUpTitle: ""
|
||||||
property int popupY: height
|
property int popupY: height
|
||||||
Accessible.name: popup.visible ?
|
Accessible.name: popup.visible ?
|
||||||
|
|
|
||||||
|
|
@ -88,7 +88,7 @@ Item {
|
||||||
active: mainItem.recording && !mainItem.chatMessageContentGui
|
active: mainItem.recording && !mainItem.chatMessageContentGui
|
||||||
property int duration: item?.core.duration || 0
|
property int duration: item?.core.duration || 0
|
||||||
property int captureVolume: item?.core.captureVolume || 0
|
property int captureVolume: item?.core.captureVolume || 0
|
||||||
property var state: item?.core.state
|
property var recorderState: item?.core.state
|
||||||
|
|
||||||
Connections {
|
Connections {
|
||||||
target: mainItem
|
target: mainItem
|
||||||
|
|
@ -120,7 +120,7 @@ Item {
|
||||||
: chatMessageContentGui.core.fileDuration
|
: chatMessageContentGui.core.fileDuration
|
||||||
progressPosition: 0
|
progressPosition: 0
|
||||||
value: 0
|
value: 0
|
||||||
recording: recorderLoader.state === LinphoneEnums.RecorderState.Running
|
recording: recorderLoader.recorderState === LinphoneEnums.RecorderState.Running
|
||||||
function refresh(){
|
function refresh(){
|
||||||
if(soudPlayerLoader.item){
|
if(soudPlayerLoader.item){
|
||||||
soudPlayerLoader.item.core.lRefreshPosition()
|
soudPlayerLoader.item.core.lRefreshPosition()
|
||||||
|
|
|
||||||
|
|
@ -25,7 +25,7 @@ ColumnLayout{
|
||||||
signal editAccount(AccountGui account)
|
signal editAccount(AccountGui account)
|
||||||
readonly property var childrenWidth: Utils.getSizeWithScreenRatio(517)
|
readonly property var childrenWidth: Utils.getSizeWithScreenRatio(517)
|
||||||
|
|
||||||
readonly property real spacing: Utils.getSizeWithScreenRatio(16)
|
spacing: Utils.getSizeWithScreenRatio(16)
|
||||||
required property var getPreviousItem
|
required property var getPreviousItem
|
||||||
required property var getNextItem
|
required property var getNextItem
|
||||||
property AccountProxy accountProxy
|
property AccountProxy accountProxy
|
||||||
|
|
@ -63,16 +63,15 @@ ColumnLayout{
|
||||||
index) : null
|
index) : null
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
ColumnLayout {
|
||||||
Repeater{
|
Repeater{
|
||||||
model: AccountProxy {
|
model: AccountProxy {
|
||||||
id: accountProxy
|
id: accountProxy
|
||||||
|
}
|
||||||
|
delegate: contactDelegate
|
||||||
}
|
}
|
||||||
delegate: contactDelegate
|
|
||||||
}
|
}
|
||||||
HorizontalBar{
|
HorizontalBar{
|
||||||
Layout.topMargin: mainItem.spacing
|
|
||||||
Layout.bottomMargin: mainItem.spacing
|
|
||||||
visible: addAccountButton.visible
|
visible: addAccountButton.visible
|
||||||
color: DefaultStyle.main2_300
|
color: DefaultStyle.main2_300
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -38,7 +38,6 @@ AbstractMainPage {
|
||||||
id: accountProxy
|
id: accountProxy
|
||||||
}
|
}
|
||||||
property AccountGui account: accountProxy.defaultAccount
|
property AccountGui account: accountProxy.defaultAccount
|
||||||
property var state: account && account.core?.registrationState || 0
|
|
||||||
property bool isRegistered: account ? account.core?.registrationState
|
property bool isRegistered: account ? account.core?.registrationState
|
||||||
== LinphoneEnums.RegistrationState.Ok : false
|
== LinphoneEnums.RegistrationState.Ok : false
|
||||||
property int selectedParticipantsCount
|
property int selectedParticipantsCount
|
||||||
|
|
|
||||||
|
|
@ -28,7 +28,6 @@ AbstractMainPage {
|
||||||
id: accountProxy
|
id: accountProxy
|
||||||
}
|
}
|
||||||
property AccountGui account: accountProxy.defaultAccount
|
property AccountGui account: accountProxy.defaultAccount
|
||||||
property var state: account && account.core?.registrationState || 0
|
|
||||||
property bool isRegistered: account ? account.core?.registrationState
|
property bool isRegistered: account ? account.core?.registrationState
|
||||||
== LinphoneEnums.RegistrationState.Ok : false
|
== LinphoneEnums.RegistrationState.Ok : false
|
||||||
|
|
||||||
|
|
@ -114,7 +113,7 @@ AbstractMainPage {
|
||||||
clip: true
|
clip: true
|
||||||
initialItem: chatListItem
|
initialItem: chatListItem
|
||||||
focus: true
|
focus: true
|
||||||
onActiveFocusChanged: if (activeFocus) {
|
onActiveFocusChanged: if (activeFocus && currentItem) {
|
||||||
currentItem.forceActiveFocus()
|
currentItem.forceActiveFocus()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -336,9 +336,9 @@ AbstractMainPage {
|
||||||
Component {
|
Component {
|
||||||
id: contactDetail
|
id: contactDetail
|
||||||
Item {
|
Item {
|
||||||
|
objectName: "contactDetail"
|
||||||
width: parent?.width
|
width: parent?.width
|
||||||
height: parent?.height
|
height: parent?.height
|
||||||
property string objectName: "contactDetail"
|
|
||||||
|
|
||||||
function focusEditButton(){
|
function focusEditButton(){
|
||||||
contactDetail.button.forceActiveFocus(Qt.TabFocusReason)
|
contactDetail.button.forceActiveFocus(Qt.TabFocusReason)
|
||||||
|
|
@ -928,7 +928,7 @@ AbstractMainPage {
|
||||||
Component {
|
Component {
|
||||||
id: contactEdition
|
id: contactEdition
|
||||||
ContactEdition {
|
ContactEdition {
|
||||||
property string objectName: "contactEdition"
|
objectName: "contactEdition"
|
||||||
onCloseEdition: redirectAddress => {
|
onCloseEdition: redirectAddress => {
|
||||||
goToContactDetails(true)
|
goToContactDetails(true)
|
||||||
if (redirectAddress) {
|
if (redirectAddress) {
|
||||||
|
|
|
||||||
|
|
@ -145,7 +145,7 @@ AbstractMainPage {
|
||||||
Component {
|
Component {
|
||||||
id: listLayout
|
id: listLayout
|
||||||
FocusScope{
|
FocusScope{
|
||||||
property string objectName: "listLayout"
|
objectName: "listLayout"
|
||||||
property alias newConfButton: newConfButton
|
property alias newConfButton: newConfButton
|
||||||
Control.StackView.onDeactivated: {
|
Control.StackView.onDeactivated: {
|
||||||
mainItem.selectedConference = null
|
mainItem.selectedConference = null
|
||||||
|
|
|
||||||
|
|
@ -1339,7 +1339,7 @@ AbstractWindow {
|
||||||
Component {
|
Component {
|
||||||
id: inCallItem
|
id: inCallItem
|
||||||
Loader {
|
Loader {
|
||||||
property string objectName: "inCallItem"
|
objectName: "inCallItem"
|
||||||
asynchronous: true
|
asynchronous: true
|
||||||
sourceComponent: Item {
|
sourceComponent: Item {
|
||||||
CallLayout {
|
CallLayout {
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue