… | |
… | |
90 | 0 |
90 | 0 |
91 | }, |
91 | }, |
92 | )); |
92 | )); |
93 | |
93 | |
94 | $self->{initiated} = 1; # for update_info |
94 | $self->{initiated} = 1; # for update_info |
|
|
95 | $self->update_tooltip; |
95 | |
96 | |
96 | $self |
97 | $self |
97 | } |
98 | } |
98 | |
99 | |
99 | # (private) This method updates the channel info associated with this chat view. |
100 | # (private) This method updates the channel info associated with this chat view. |
… | |
… | |
104 | $self->{say_command} = $info->{reply}; |
105 | $self->{say_command} = $info->{reply}; |
105 | $self->{entry_tooltip} = |
106 | $self->{entry_tooltip} = |
106 | $info->{entry_tooltip} |
107 | $info->{entry_tooltip} |
107 | || "Enter a message and press enter to send it to the channel '$info->{title}'."; |
108 | || "Enter a message and press enter to send it to the channel '$info->{title}'."; |
108 | |
109 | |
109 | # TODO: needs some testing maybe, if known that this works: remove comment! |
|
|
110 | if ($self->{initiated}) { |
110 | if ($self->{initiated}) { |
111 | $self->{say_command_label}->set_markup ($self->{say_command}); |
111 | $self->{say_command_label}->set_markup ($self->{say_command}); |
112 | $self->{txt}->{tooltip} = $self->{text_tooltip}; |
|
|
113 | $self->{input}->{tooltip} = $self->{entry_tooltip}; |
|
|
114 | $self->set_title ($self->{title}); |
112 | $self->set_title ($self->{title}); |
|
|
113 | $self->update_tooltip; |
115 | } |
114 | } |
116 | } |
115 | } |
117 | |
116 | |
|
|
117 | # updates only the |
118 | sub update_tooltip { |
118 | sub update_tooltip { |
119 | my ($self) = @_; |
119 | my ($self) = @_; |
120 | my $t = $self->{text_tooltip} |
120 | my $t = $self->{text_tooltip} |
121 | . (defined $self->{dockbar_pos} |
121 | . (defined $self->{dockbar_pos} |
122 | ? "\n\n<small>Alt+" |
122 | ? "\n\n<small>Alt+" |
… | |
… | |
124 | . " - activates this tab.\n" |
124 | . " - activates this tab.\n" |
125 | . "Return - toggles activity of the entry." |
125 | . "Return - toggles activity of the entry." |
126 | . "</small>" |
126 | . "</small>" |
127 | : ""); |
127 | : ""); |
128 | $self->{c_tab}->set_tooltip ($t); |
128 | $self->{c_tab}->set_tooltip ($t); |
|
|
129 | $self->{txt}->{tooltip} = $self->{text_tooltip}; |
|
|
130 | $self->{input}->{tooltip} = $self->{entry_tooltip}; |
129 | } |
131 | } |
130 | |
132 | |
131 | sub set_dockbar_pos { |
133 | sub set_dockbar_pos { |
132 | my ($self, @a) = @_; |
134 | my ($self, @a) = @_; |
133 | $self->SUPER::set_dockbar_pos (@a); |
135 | $self->SUPER::set_dockbar_pos (@a); |