Selenium IDE mouse scroll for pop up menu? - selenium

I am working on selinium IDE. I wan to use mouse scroll command to a pop up menu. it works perfectly fine with window scroll bar. But can't use for pop up menu scroll bar.
"selenium.browserbot.getCurrentWindow()" will scroll the main window only. Not the one that currently active.
Command Target Value
store 40 i
store 0 looptimes
while storedVars.looptimes <= 20
storeEval selenium.browserbot.getCurrentWindow().scrollTo(0,${i})
store javascript{storedVars.looptimes++;}
storeEval ${i}+40 i
endWhile
I am attaching screen shot of command and my screen.
The above is the code. below is my pop up menu
Please tell me how to do this.

You will need to tell selenium to change framesI think, to do this you will have to use the selectFrameCommand:
selectFrame ( locator ) Selects a frame within the current window.
(You may invoke this command multiple times to select nested frames.)
To select the parent frame, use "relative=parent" as a locator; to
select the top frame, use "relative=top". You can also select a frame
by its 0-based index number; select the first frame with "index=0", or
the third frame with "index=2". You may also use a DOM expression to
identify the frame you want directly, like this:
dom=frames["main"].frames["subframe"]
Arguments:
locator - an element locator identifying a frame or iframe
Once you have changed to the correct frame the mouse scroll should work

Related

i want to scroll a voew to right and click on 3 dots, sometimes automatically it detects the button, sometimes not

I have to scroll right in cypress for a specific view part. Sometimes it automatically detect, but sometimes after scroll only it detect the button. Scrollbar has no unique ID. What is the solution for this scenario?
I tried cy.scroll(500,0) but this dont work
You can get the element then use .scrollIntoView() chained to the returned element.
cy.get('#uniqueId')
.scrollIntoView()
// now it will be in current viewport

Sliding a frameless window in and out of screen edge in qml

As the title says, I want to move, clicking a button in task bar , a frameless window out and in of screen right edge .One way to achieve this under kde neon in QML, is to create a PlasmaCore.Dialog{} window and setting as flags the Qt.X11BypassWindowManagerHint only, so the window manager is bypassed.The problem with this solution is that, inside window, where i "append" some widgets in a ListView, I can not have activeFocus to TextArea and I can not type anything there. The TextArea gains activeFocus only if I use as flags the Qt.Popup only without Qt.X11BypassWindowManagerHint.
So is there an alternative solution of making the window sliding in an out from screen right edge without using the flags of Qt.X11BypassWindowManagerHint? In the below link is the code I am using now for sliding window:
https://gist.github.com/cgiannakidis70/8a0ea61d7f18e803381159d7456e2135
EDIT 1
After a lot trying and error I found that the use of flags Qt.BypassWindowManagerHint and Qt.Popup do the trick.Now I can slide the window outside screen edge and also type in TextArea inside a widget .

I want to scroll the window after popup in selenium

In Selenium, I want to retrieve or scroll elements in a popup window as shown in the figure.
The usual "driver.find_elements_by_class_name~" will not get the elements in the popup window.
handle_array = driver.window_handles
driver.switch_to.window(handle_array[1])
I could not get it by using
How can I get it?
CLICK IMAGE

Selenium IDE - selecting an button outside the frame

I am relatively new to Selenium. We are using the Selenium IDE to do some regression testing. I have a menu bar that has different buttons on it that will drop down a menu when you hover over any of the buttons (there are 4 buttons on the menu bar). So when i select one of the menu items from the dropdown, it opens a page inside the same window. This page looking at the debug info in Selenium seems to be a frame. This frame open right under the menu bar and the menu bar is still visible. Once the page has loaded completely, I want to go outside the frame and click on a button on the menu bar and click on the next item to verify. This doesnt seem to work, once the page (frame) has loaded then nothing happens. I have tried using window focus, select frame, mouse over commands but nothing seem to work. i have also used the relative = parent and relative = top commands with the select frame command but cant get it to work.
Any tips or suggestions are welcome. If I am not clear on the description I can provide more details. Thanks for the assist.
If the control is outside of the frame Selenium is pointing to, then you need to switch back to default content, and possibly switch to the frame the control is in.
Driver.SwitchTo().DefaultContent();
Driver.SwitchTo().Frame(frameID);
you should firstly switch to appropriate frame where your button is located in:
1. Switch to frame
Command: selectFrame
Target: your_frame_id
2. Click button
Command: click
Target: your_button_id (or you can use XPath or CSS selector instead)

xulrunner tab close button

I have an xul window with a tab box. The tab and tappanel elements are generated as needed in Javascript.
I want the tabs to have a close button. The docs for the 'tabs' tag talks about a 'closebutton' attribute buts says it is no longer supported.
I am trying to create content inside the tab. Right now it contains two label tags. The first is the actual tab label and the second is a red X (actually unicode \u2716). It displays fine but I cannot seem to get an event to fire when the X is clicked.
I have tried using the onclick attribute and closebutton.addEventListener('click').
I also tried using a toolbarbutton instead of a label. It displays the X but does not draw the button around it when the mouse hovers. Most importantly I cannot get the button event to fire.