Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vmj-qt
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Kulya
vmj-qt
Commits
5a3ca07a
Commit
5a3ca07a
authored
May 24, 2022
by
Tijmen de Mes
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Added setting to enable IMDN per account
parent
ce2a7839
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
69 additions
and
21 deletions
+69
-21
account.py
blink/configuration/account.py
+1
-0
preferences.py
blink/preferences.py
+10
-0
preferences.ui
resources/preferences.ui
+58
-21
No files found.
blink/configuration/account.py
View file @
5a3ca07a
...
...
@@ -64,6 +64,7 @@ class ServerSettings(SettingsGroup):
class
SMSSettings
(
SettingsGroup
):
use_cpim
=
Setting
(
type
=
bool
,
default
=
True
)
enable_iscomposing
=
Setting
(
type
=
bool
,
default
=
True
)
enable_imdn
=
Setting
(
type
=
bool
,
default
=
True
)
class
SoundSettings
(
SettingsGroup
):
...
...
blink/preferences.py
View file @
5a3ca07a
...
...
@@ -256,8 +256,10 @@ class PreferencesWindow(base_class, ui_class, metaclass=QSingleton):
self
.
prefix_button
.
activated
[
str
]
.
connect
(
self
.
_SH_PrefixButtonActivated
)
self
.
account_tls_name_editor
.
editingFinished
.
connect
(
self
.
_SH_TLSPeerNameEditorEditingFinished
)
# Account sms settings
self
.
message_cpim_enabled_button
.
clicked
.
connect
(
self
.
_SH_EnableMessageCPIMButtonClicked
)
self
.
message_iscomposing_enabled_button
.
clicked
.
connect
(
self
.
_SH_EnableMessageIsComposingButtonClicked
)
self
.
message_imdn_enabled_button
.
clicked
.
connect
(
self
.
_SH_EnableMessageIMDNButtonClicked
)
# Audio devices
self
.
audio_alert_device_button
.
activated
[
int
]
.
connect
(
self
.
_SH_AudioAlertDeviceButtonActivated
)
...
...
@@ -829,6 +831,8 @@ class PreferencesWindow(base_class, ui_class, metaclass=QSingleton):
# SMS settings tab, also relevant for bonjour
self
.
message_cpim_enabled_button
.
setChecked
(
account
.
sms
.
use_cpim
)
self
.
message_iscomposing_enabled_button
.
setChecked
(
account
.
sms
.
enable_iscomposing
)
self
.
message_imdn_enabled_button
.
setEnabled
(
account
.
sms
.
use_cpim
)
self
.
message_imdn_enabled_button
.
setChecked
(
account
.
sms
.
enable_imdn
)
if
account
is
not
bonjour_account
:
self
.
account_auto_answer
.
setText
(
'Auto answer from allowed contacts'
)
...
...
@@ -1420,6 +1424,7 @@ class PreferencesWindow(base_class, ui_class, metaclass=QSingleton):
def
_SH_EnableMessageCPIMButtonClicked
(
self
,
checked
):
account
=
self
.
selected_account
account
.
sms
.
use_cpim
=
checked
self
.
message_imdn_enabled_button
.
setEnabled
(
account
.
sms
.
use_cpim
)
account
.
save
()
def
_SH_EnableMessageIsComposingButtonClicked
(
self
,
checked
):
...
...
@@ -1427,6 +1432,11 @@ class PreferencesWindow(base_class, ui_class, metaclass=QSingleton):
account
.
sms
.
enable_iscomposing
=
checked
account
.
save
()
def
_SH_EnableMessageIMDNButtonClicked
(
self
,
checked
):
account
=
self
.
selected_account
account
.
sms
.
enable_imdn
=
checked
account
.
save
()
# Audio devices signal handlers
def
_SH_AudioAlertDeviceButtonActivated
(
self
,
index
):
device
=
self
.
audio_alert_device_button
.
itemData
(
index
)
...
...
resources/preferences.ui
View file @
5a3ca07a
...
...
@@ -1278,34 +1278,21 @@
<property
name=
"bottomMargin"
>
<number>
0
</number>
</property>
<item
row=
"
4"
column=
"0
"
>
<widget
class=
"QCheckBox"
name=
"message_
cpim
_enabled_button"
>
<item
row=
"
5"
column=
"1
"
>
<widget
class=
"QCheckBox"
name=
"message_
iscomposing
_enabled_button"
>
<property
name=
"text"
>
<string>
Use CPIM envelope
</string>
<string>
Enable Is-Composing
</string>
</property>
</widget>
</item>
<item
row=
"2"
column=
"
0
"
>
<item
row=
"2"
column=
"
1
"
>
<widget
class=
"Line"
name=
"line_2"
>
<property
name=
"orientation"
>
<enum>
Qt::Horizontal
</enum>
</property>
</widget>
</item>
<item
row=
"6"
column=
"0"
>
<spacer
name=
"verticalSpacer"
>
<property
name=
"orientation"
>
<enum>
Qt::Vertical
</enum>
</property>
<property
name=
"sizeHint"
stdset=
"0"
>
<size>
<width>
20
</width>
<height>
20
</height>
</size>
</property>
</spacer>
</item>
<item
row=
"1"
column=
"0"
>
<item
row=
"1"
column=
"1"
>
<widget
class=
"QLabel"
name=
"message_label"
>
<property
name=
"font"
>
<font>
...
...
@@ -1321,16 +1308,66 @@
</property>
</widget>
</item>
<item
row=
"
5"
column=
"0
"
>
<widget
class=
"QCheckBox"
name=
"message_
iscomposing
_enabled_button"
>
<item
row=
"
4"
column=
"1
"
>
<widget
class=
"QCheckBox"
name=
"message_
cpim
_enabled_button"
>
<property
name=
"text"
>
<string>
Enable Is-Composing
</string>
<string>
Use CPIM envelope
</string>
</property>
</widget>
</item>
<item
row=
"7"
column=
"1"
>
<widget
class=
"QLabel"
name=
"label"
>
<property
name=
"font"
>
<font>
<weight>
75
</weight>
<bold>
true
</bold>
</font>
</property>
<property
name=
"text"
>
<string>
When sending and receiving messages
</string>
</property>
</widget>
</item>
<item
row=
"8"
column=
"1"
>
<widget
class=
"Line"
name=
"line_4"
>
<property
name=
"orientation"
>
<enum>
Qt::Horizontal
</enum>
</property>
</widget>
</item>
</layout>
</widget>
</item>
<item
row=
"1"
column=
"0"
>
<widget
class=
"QCheckBox"
name=
"message_imdn_enabled_button"
>
<property
name=
"text"
>
<string>
Enable IMDN (Read receipts)
</string>
</property>
</widget>
</item>
<item
row=
"3"
column=
"0"
>
<spacer
name=
"verticalSpacer"
>
<property
name=
"orientation"
>
<enum>
Qt::Vertical
</enum>
</property>
<property
name=
"sizeHint"
stdset=
"0"
>
<size>
<width>
20
</width>
<height>
20
</height>
</size>
</property>
</spacer>
</item>
<item
row=
"2"
column=
"0"
>
<widget
class=
"QLabel"
name=
"label_4"
>
<property
name=
"enabled"
>
<bool>
false
</bool>
</property>
<property
name=
"text"
>
<string>
If you turn off IMDN you won't be able to see receipts from other people
</string>
</property>
</widget>
</item>
</layout>
</widget>
<widget
class=
"QWidget"
name=
"advanced_tab"
>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment