File tree Expand file tree Collapse file tree 3 files changed +14
-1
lines changed Expand file tree Collapse file tree 3 files changed +14
-1
lines changed Original file line number Diff line number Diff line change @@ -97,6 +97,8 @@ impl Chat {
97
97
98
98
if chat. param . exists ( Param :: Selftalk ) {
99
99
chat. name = context. stock_str ( StockMessage :: SelfMsg ) . into ( ) ;
100
+ } else if chat. param . exists ( Param :: Devicetalk ) {
101
+ chat. name = context. stock_str ( StockMessage :: DeviceMessages ) . into ( ) ;
100
102
}
101
103
}
102
104
}
Original file line number Diff line number Diff line change @@ -153,7 +153,16 @@ impl Contact {
153
153
blocked : false ,
154
154
origin : Origin :: Unknown ,
155
155
} ;
156
-
156
+ return Ok ( contact) ;
157
+ } else if contact_id == DC_CONTACT_ID_DEVICE {
158
+ let contact = Contact {
159
+ id : contact_id,
160
+ name : context. stock_str ( StockMessage :: DeviceMessages ) . into ( ) ,
161
+ authname : "" . into ( ) ,
162
+ addr : "device@localhost" . into ( ) ,
163
+ blocked : false ,
164
+ origin : Origin :: Unknown ,
165
+ } ;
157
166
return Ok ( contact) ;
158
167
}
159
168
Original file line number Diff line number Diff line change @@ -110,6 +110,8 @@ pub enum StockMessage {
110
110
Location = 66 ,
111
111
#[ strum( props( fallback = "Sticker" ) ) ]
112
112
Sticker = 67 ,
113
+ #[ strum( props( fallback = "Device Messages" ) ) ]
114
+ DeviceMessages = 68 ,
113
115
}
114
116
115
117
impl StockMessage {
You can’t perform that action at this time.
0 commit comments