com.opera.core.systems.scope.services
Interface IDesktopWindowManager

All Known Implementing Classes:
DesktopWindowManager

public interface IDesktopWindowManager

Author:
Adam Minchinton , Karianne Ekern

Method Summary
 int getActiveQuickWindowId()
          Gets id of active window.
 int getOpenQuickWindowCount()
          Gets number of open windows.
 QuickMenu getQuickMenu(java.lang.String menuName)
          Gets the menu with name name.
 QuickMenu getQuickMenu(java.lang.String menuName, int windowId)
           
 QuickMenuItem getQuickMenuItemByAccKey(java.lang.String key, java.lang.String menuName)
          Gets the menu item with the given accelerator key in the menu with name menuName.
 QuickMenuItem getQuickMenuItemByAction(java.lang.String action)
          Gets the menu with the action specified, if any.
 QuickMenuItem getQuickMenuItemByName(java.lang.String name)
           
 QuickMenuItem getQuickMenuItemByName(java.lang.String name, int window_id)
           
 QuickMenuItem getQuickMenuItemByPosition(int row, java.lang.String menuName)
          Gets the menu item with the given position in the menu with name menuName.
 QuickMenuItem getQuickMenuItemByShortcut(java.lang.String shortcut)
          Gets the Menu item with the given shortcut.
 QuickMenuItem getQuickMenuItemBySubmenu(java.lang.String submenu)
          Gets the menu item that opens the sub-menu.
 QuickMenuItem getQuickMenuItemByText(java.lang.String text)
          Gets the menu with the text specified, if any.
 java.util.List<QuickMenuItem> getQuickMenuItemList()
           
 java.util.List<QuickMenu> getQuickMenuList()
           
 QuickWidget getQuickWidget(DesktopWmProtos.QuickWidgetInfo.QuickWidgetType type, int windowId, DesktopWmProtos.QuickWidgetSearch.QuickWidgetSearchType property, java.lang.String value)
          Gets a QuickWidget based on a specific property.
 QuickWidget getQuickWidget(DesktopWmProtos.QuickWidgetInfo.QuickWidgetType type, int windowId, DesktopWmProtos.QuickWidgetSearch.QuickWidgetSearchType property, java.lang.String value, java.lang.String parentName)
          Gets the quick widget in a specified window based on a specific property and its parent widgets name.
 QuickWidget getQuickWidgetByPos(DesktopWmProtos.QuickWidgetInfo.QuickWidgetType type, int windowId, int row, int column)
          Gets the quick widget based on its position.
 QuickWidget getQuickWidgetByPos(DesktopWmProtos.QuickWidgetInfo.QuickWidgetType type, int windowId, int row, int column, java.lang.String parentName)
          Gets the quick widget based on its position and its parent widgets name.
 java.util.List<QuickWidget> getQuickWidgetList(int windowId)
          Gets list of all QuickWidgets in the window.
 QuickWindow getQuickWindow(DesktopWmProtos.QuickWidgetSearch.QuickWidgetSearchType property, java.lang.String value)
          Gets the quick window based on a specific property.
 QuickWindow getQuickWindowById(int windowId)
          Gets the quick window with the given window id.
 QuickWindow getQuickWindowByName(java.lang.String name)
          Gets the window with name name.
 int getQuickWindowID(java.lang.String name)
          Gets window id of window with the given name.
 java.util.List<QuickWindow> getQuickWindowList()
          Gets a list of all open windows.
 java.lang.String getQuickWindowName(int windowId)
          Gets the name of the window with windowId.
 void init()
          Does initialization necessary to set up the service.
 void pressQuickMenuItem(java.lang.String menuItemText, boolean popMenu)
           
 

Method Detail

init

void init()
Does initialization necessary to set up the service.


getActiveQuickWindowId

int getActiveQuickWindowId()
Gets id of active window.

Returns:
id of active window

getOpenQuickWindowCount

int getOpenQuickWindowCount()
Gets number of open windows.

Returns:
number of open windows

getQuickWidgetList

java.util.List<QuickWidget> getQuickWidgetList(int windowId)
Gets list of all QuickWidgets in the window.

Parameters:
windowId - id of window
Returns:
list of QuickWidgets in the window given by id id

getQuickWindowID

int getQuickWindowID(java.lang.String name)
Gets window id of window with the given name.

Parameters:
name - window name
Returns:
id of window with the given name

getQuickWindowList

java.util.List<QuickWindow> getQuickWindowList()
Gets a list of all open windows.

Returns:
list of all open windows

getQuickWindowName

java.lang.String getQuickWindowName(int windowId)
Gets the name of the window with windowId.

Parameters:
windowId - id of window
Returns:
name of the window

getQuickWidget

QuickWidget getQuickWidget(DesktopWmProtos.QuickWidgetInfo.QuickWidgetType type,
                           int windowId,
                           DesktopWmProtos.QuickWidgetSearch.QuickWidgetSearchType property,
                           java.lang.String value)
Gets a QuickWidget based on a specific property.

Parameters:
type - what type
windowId - window id of the window containing the widget
property - property specified for the search
value - value of property given
Returns:
QuickWidget matching the property, or null if no such widget

getQuickWidget

QuickWidget getQuickWidget(DesktopWmProtos.QuickWidgetInfo.QuickWidgetType type,
                           int windowId,
                           DesktopWmProtos.QuickWidgetSearch.QuickWidgetSearchType property,
                           java.lang.String value,
                           java.lang.String parentName)
Gets the quick widget in a specified window based on a specific property and its parent widgets name.

Parameters:
type - what type
windowId - window id of the window containing the widget
property - property specified for the search
value - value of property given
parentName - Name of the widgets parent widget
Returns:
QuickWidget matching the property, or null if no such widget

getQuickWidgetByPos

QuickWidget getQuickWidgetByPos(DesktopWmProtos.QuickWidgetInfo.QuickWidgetType type,
                                int windowId,
                                int row,
                                int column)
Gets the quick widget based on its position.

Parameters:
type - what type
windowId - window id of the window containing the widget
row - row of the widget
column - column of the widget
Returns:
QuickWidget matching the parameters, or null if no such widget

getQuickWidgetByPos

QuickWidget getQuickWidgetByPos(DesktopWmProtos.QuickWidgetInfo.QuickWidgetType type,
                                int windowId,
                                int row,
                                int column,
                                java.lang.String parentName)
Gets the quick widget based on its position and its parent widgets name.

Parameters:
type - what type
windowId - window id of the window containing the widget
row - row of the widget
column - column of the widget
parentName - Name of the widgets parent widget
Returns:
QuickWidget matching the parameters, or null if no such widget

getQuickWindow

QuickWindow getQuickWindow(DesktopWmProtos.QuickWidgetSearch.QuickWidgetSearchType property,
                           java.lang.String value)
Gets the quick window based on a specific property.

Parameters:
property - - property to search by
value - - value of property given
Returns:
QuickWindow matching the parameters, or null if no such widget

getQuickWindowById

QuickWindow getQuickWindowById(int windowId)
Gets the quick window with the given window id.

Parameters:
windowId - id of the window
Returns:
QuickWindow with id windowId, if any, else null.

getQuickWindowByName

QuickWindow getQuickWindowByName(java.lang.String name)
Gets the window with name name.

Parameters:
name - window name
Returns:
QuickWindow

pressQuickMenuItem

void pressQuickMenuItem(java.lang.String menuItemText,
                        boolean popMenu)

getQuickMenu

QuickMenu getQuickMenu(java.lang.String menuName)
Gets the menu with name name.

Parameters:
menuName - the menu's name
Returns:
QuickMenu

getQuickMenuItemByAction

QuickMenuItem getQuickMenuItemByAction(java.lang.String action)
Gets the menu with the action specified, if any.

Parameters:
action - of the menu item to search for
Returns:
QuickMenuItem with action, or null if the item doesn't exist

getQuickMenuItemByText

QuickMenuItem getQuickMenuItemByText(java.lang.String text)
Gets the menu with the text specified, if any.

Parameters:
text - of the menu item to search for
Returns:
QuickMenuItem with the given text, or null if no such item exists

getQuickMenuItemByPosition

QuickMenuItem getQuickMenuItemByPosition(int row,
                                         java.lang.String menuName)
Gets the menu item with the given position in the menu with name menuName.

Parameters:
row - the row of the item, counting from zero, and including both normal items and menu separators
menuName - name of the menu to lookup the menu item in
Returns:
QuickMenuItem, or null if the item doesn't exist

getQuickMenuItemByAccKey

QuickMenuItem getQuickMenuItemByAccKey(java.lang.String key,
                                       java.lang.String menuName)
Gets the menu item with the given accelerator key in the menu with name menuName.

Parameters:
key - the shortcut key of the menu item to search for (the character that's underlined/marked in the menu item text)
menuName - name of the menu of the menu item
Returns:
QuickMenuItem or null if the item doesn't exist

getQuickMenuItemByShortcut

QuickMenuItem getQuickMenuItemByShortcut(java.lang.String shortcut)
Gets the Menu item with the given shortcut.

Parameters:
shortcut - string representation of the shortcut of the menuitem (i.e. "Ctrl+O")
Returns:
QuickMenuItem, or null if the item doesnt exist

getQuickMenuItemBySubmenu

QuickMenuItem getQuickMenuItemBySubmenu(java.lang.String submenu)
Gets the menu item that opens the sub-menu.

Parameters:
submenu - the name of the sub-menu the menu item opens when its selected/clicked
Returns:
QuickMenuItem or null if the item doesn't exist

getQuickMenuList

java.util.List<QuickMenu> getQuickMenuList()
Returns:
list of all menus that are open (including menu bar(s))

getQuickMenuItemList

java.util.List<QuickMenuItem> getQuickMenuItemList()
Returns:
list containing all menu items in open menus (including menu bar(s))

getQuickMenuItemByName

QuickMenuItem getQuickMenuItemByName(java.lang.String name)
Parameters:
name - name of the item. This is either the name of the action the item executes when selected The name of the sub-menu the item opens when selected "Separator" for items that are separators
Returns:
the menu item

getQuickMenu

QuickMenu getQuickMenu(java.lang.String menuName,
                       int windowId)
Parameters:
menuName - name of the menu (as specified in standard_menu.ini)
windowId - id of the window the menu is attached to (note: only makes sense for menu bar)
Returns:
QuickMenu with name menuName in windowId if it exists, else null

getQuickMenuItemByName

QuickMenuItem getQuickMenuItemByName(java.lang.String name,
                                     int window_id)
Parameters:
name - Name of the menuItem
window_id - windowId of the window the menu of the item is in (note: only makes sense for menu bar items)
Returns:
the menu item


Copyright © 2011. All Rights Reserved.