don't scroll to end each time we press a key in message textview, but only when scrollbar appear. fixes #2944
This commit is contained in:
parent
d83d744a27
commit
7d8f7e2a6e
|
@ -717,6 +717,10 @@ class ChatControlBase(MessageControl):
|
||||||
if diff_y != 0:
|
if diff_y != 0:
|
||||||
if conversation_height + diff_y < min_height:
|
if conversation_height + diff_y < min_height:
|
||||||
if message_height + conversation_height - min_height > min_height:
|
if message_height + conversation_height - min_height > min_height:
|
||||||
|
policy = self.msg_scrolledwindow.get_property(
|
||||||
|
'vscrollbar-policy')
|
||||||
|
# scroll only when scrollbar appear
|
||||||
|
if policy != gtk.POLICY_AUTOMATIC:
|
||||||
self.msg_scrolledwindow.set_property('vscrollbar-policy',
|
self.msg_scrolledwindow.set_property('vscrollbar-policy',
|
||||||
gtk.POLICY_AUTOMATIC)
|
gtk.POLICY_AUTOMATIC)
|
||||||
self.msg_scrolledwindow.set_property('height-request',
|
self.msg_scrolledwindow.set_property('height-request',
|
||||||
|
|
Loading…
Reference in New Issue