Comments (9)
I've approved the new version on e.g.o. The bugfix is now available via the known distribution channel.
It's quite hard for us to spot such issues beforehand during the review process.
from no-title-bar.
Same issue here.
from no-title-bar.
Looking at the changes between v6 and v7, it seems like the issue is the new _enableDragOnPanel
/ _disableDragOnPanel
functions in buttons.js
that was introduced in 52ad939
If the 'button-position' setting is "HIDDEN" then the Buttons
constructor calls into the this._disable()
method, which blindly calls this._disableDragOnPanel()
. This "helpfully" sets the global Main.panel._onButtonPress
to null
, because this._originalFunction
was never initialized, and then tries to bind null
to Main.panel
.
In the meantime, if you edit ~/.local/share/gnome-shell/extensions/[email protected]/buttons.js
and add return
to the top of the _enableDragOnPanel
and _disableDragOnPanel
functions to disable them, then restart gnome-shell, the extension seems to work fine for me.
_enableDragOnPanel: function() {
print('IGNORING BUGGY FUNCTION');
return;
this._originalFunction = Main.panel._onButtonPress;
Main.panel._onButtonPress = function(actor, event) {
if (Main.modalCount > 0)
return Clutter.EVENT_PROPAGATE;
if (event.get_source() != actor)
return Clutter.EVENT_PROPAGATE;
let button = event.get_button();
if (button != 1)
return Clutter.EVENT_PROPAGATE;
let focusWindow = Utils.getWindow(true);
if (!focusWindow)
return Clutter.EVENT_PROPAGATE;
let dragWindow = focusWindow.is_attached_dialog() ? focusWindow.get_transient_for()
: focusWindow;
if (!dragWindow)
return Clutter.EVENT_PROPAGATE;
let rect = dragWindow.get_frame_rect();
let [stageX, stageY] = event.get_coords();
let allowDrag = dragWindow.maximized_vertically &&
stageX > rect.x && stageX < rect.x + rect.width;
if (!allowDrag)
return Clutter.EVENT_PROPAGATE;
global.display.begin_grab_op(global.screen,
dragWindow,
Meta.GrabOp.MOVING,
false, /* pointer grab */
true, /* frame action */
button,
event.get_state(),
event.get_time(),
stageX, stageY);
return Clutter.EVENT_STOP;
};
Main.panel.actor.connect('button-press-event', Lang.bind(Main.panel, Main.panel._onButtonPress));
},
_disableDragOnPanel: function() {
print('IGNORING BUGGY FUNCTION');
return;
Main.panel._onButtonPress = this._originalFunction;
Main.panel.actor.connect('button-press-event', Lang.bind(Main.panel, Main.panel._onButtonPress));
},
from no-title-bar.
Hello all, thanks a lot for the prompt reporting of this problem! It was not obvious to trigger (in my usage at least).
Thanks a lot @nhinds for looking into this, as I actually didn't have that much time to investigate.
I uploaded a new version to e.g.o with the fix. If anyone could confirm that the latest git code works it would be great.
I have to say I'm flattered by the great response to this issue.
Cheers everyone,
Fran
from no-title-bar.
After installing the current master
, can confirm the extension works for me and no longer throws the Lang.bind
error on startup. Thanks for the quick response :)
from no-title-bar.
I didn't get any info about update.
I've uninstalled and installed the extension again.
The issue is still there.
Oddly enough in the dropdown I see only the version 6.
I don't know how to check the version which I've installed.
From my experience some tools don't re-fetch the package if the version didn't change.
from no-title-bar.
@szuliq I inactivated version 7, hence the extension website should offer version 6 as an "update" (since 7 is faulty). Perhaps it isn't doing that.
- If you want, you can install from git, like so:
git clone https://github.com/franglais125/no-title-bar
cd no-title-bar
make && make install install
You might need some tools for this in Ubuntu:
sudo apt install git make gettext
- If you want to check the version information, you can run:
cat ~/.local/share/gnome-shell/extensions/[email protected]/metadata.json
from no-title-bar.
It is working great now!
from no-title-bar.
@maweki thanks for the quick reviews. I certainly don't expect you guys to catch all the bugs! With many features come many corner cases :)
Thanks everyone for the quick feedback! Closing this now.
from no-title-bar.
Related Issues (20)
- Blacklist mode is broken
- [BUG] Object St.BoxLayout (0x55c133893030), has been already deallocated HOT 1
- Add Window title as an indicator for 3.32 support
- Does not properly uninstall HOT 1
- Make compatible with Multi Monitors Add-On
- gnome 3.30.2 crashed because of no-title-bar
- Continues to remove some title bars after being disabled HOT 1
- Would it be possible to "bundle" window buttons with app menu / tile HOT 3
- Window control buttons change position after each reboot but option description within config stays the same :(
- Window control buttons missing for Evolution HOT 1
- Request to use _MOTIF_WM_HINTS since _GTK_HIDE_TITLEBAR_WHEN_MAXIMIZED is removed HOT 2
- Broken in GNOME 3.32.0 HOT 14
- Close button can be clicked with just mouseup (wayland only)
- Stopped removing title bar on Ubuntu 19.04 HOT 2
- Not working with some applications such as Blender. HOT 1
- Not remove title bar for snapped windows
- Ubuntu 20.04: the window control buttons won't move
- After waking from sleep, title bar is hidden but window size is offset HOT 1
- Error: "No JS module 'tweener' found in search path" on Ubuntu 20.10 HOT 2
- buttons and theme
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from no-title-bar.