TakeMeToTheMoon
TakeMeToTheMoon

Reputation: 547

QTabBar, remove signal tabMoved(from, to) from function moveTab(from, to)

As I am connecting a QListWidget to a QTabBar, I see that everytime I drag&drop a tab the signal tabMoved is triggered. This works perfectly.

It seems that even when I execute the function moveTab(from, to), the same signal is triggered. Is it possible to set the function moveTab not to trigger the signal tabMoved(from, to)?

Upvotes: 0

Views: 135

Answers (1)

t.m.
t.m.

Reputation: 1490

I think that will do,

myTabBar.blocksignals(true);
myTabBar.moveTab(from, to);
myTabBar.blocksignals(false);

Upvotes: 1

Related Questions