Qt 4: Move window without title bar

Try this to move the window manually: void PopupWindow::mousePressEvent(QMouseEvent *event){ mpos = event->pos(); } void PopupWindow::mouseMoveEvent(QMouseEvent *event){ if (event->buttons() & Qt::LeftButton) { QPoint diff = event->pos() – mpos; QPoint newpos = this->pos() + diff; this->move(newpos); } } And declare QPoint mpos somewhere.

Add a UIView above all, even the navigation bar

You can do that by adding your view directly to the keyWindow: UIView *myView = /* <- Your custom view */; UIWindow *currentWindow = [UIApplication sharedApplication].keyWindow; [currentWindow addSubview:myView]; UPDATE — For Swift 4.1 and above let currentWindow: UIWindow? = UIApplication.shared.keyWindow currentWindow?.addSubview(myView) UPDATE for iOS13 and above keyWindow is deprecated. You should use the following: UIApplication.shared.windows.first(where: … Read more

Blur or dim background when Android PopupWindow active

The question was about the Popupwindow class, yet everybody has given answers that use the Dialog class. Thats pretty much useless if you need to use the Popupwindow class, because Popupwindow doesn’t have a getWindow() method. I’ve found a solution that actually works with Popupwindow. It only requires that the root of the xml file … Read more

How to handle Pop-up in Selenium WebDriver using Java

To switch to a popup window, you need to use getWindowHandles() and iterate through them. In your code you are using getWindowHandle() which will give you the parent window itself. String parentWindowHandler = driver.getWindowHandle(); // Store your parent window String subWindowHandler = null; Set<String> handles = driver.getWindowHandles(); // get all window handles Iterator<String> iterator = … Read more

Android PopupWindow with Tooltip Arrow

There are many libraries and codes available into Market. Links are given below: This is the QuickAction UI pattern. Take a look at: QuickAction-Dialog Quick-action-pattern-in-Android Chrome Style Help Popups Another alternative would be “super-tooltips”: https://github.com/nhaarman/supertooltips Here’s a demo of it: https://play.google.com/store/apps/details?id=com.haarman.supertooltips From that first link/example looks like below image. These are just demos, but you … Read more

Android popup window dismissal

This is because the popup window does not respond to onTouch or onKey events unless it has a background that != null. Check out some code I wrote to help with this. In the basic case you can to call PopupWindow#setBackgroundDrawable(new BitmapDrawable()) to force it to act the way you expect. You won’t need your … Read more