Make sure button texts are shown in any case.

multiprovider
Jens Lody 10 years ago
parent 047545924f
commit fafa7d6529
  1. 3
      src/extension.js

@ -668,6 +668,7 @@ const WeatherMenuButton = new Lang.Class({
this.parseWeatherCurrent();
}));
this._buttonBox1.add_actor(button);
this._buttonBox1MinWidth = this._buttonBox1.get_width();
this._buttonBox2 = new St.BoxLayout({style_class: 'popup-menu-item'});
@ -836,7 +837,7 @@ const WeatherMenuButton = new Lang.Class({
_onOpenStateChanged: function(menu, open) {
if (open)
{
this._buttonBox1.set_width(this._currentWeather.get_width() - this._buttonBox2.get_width());
this._buttonBox1.set_width(Math.max(this._buttonBox1MinWidth,this._currentWeather.get_width() - this._buttonBox2.get_width()));
if (this._forecastScrollBox !== undefined && this._forecastBox !== undefined && this._currentWeather !== undefined) {
this._forecastScrollBox.set_width(this._currentWeather.get_width());
this._forecastScrollBox.show();

Loading…
Cancel
Save