本文整理了Java中org.eclipse.swt.widgets.Shell.bringToTop()
方法的一些代码示例,展示了Shell.bringToTop()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Shell.bringToTop()
方法的具体详情如下:
包路径:org.eclipse.swt.widgets.Shell
类名称:Shell
方法名:bringToTop
暂无
代码示例来源:origin: org.eclipse.platform/org.eclipse.swt.gtk.linux.s390x
/**
* If the receiver is visible, moves it to the top of the
* drawing order for the display on which it was created
* (so that all other shells on that display, which are not
* the receiver's children will be drawn behind it) and forces
* the window manager to make the shell active.
*
* @exception SWTException <ul>
* <li>ERROR_WIDGET_DISPOSED - if the receiver has been disposed</li>
* <li>ERROR_THREAD_INVALID_ACCESS - if not called from the thread that created the receiver</li>
* </ul>
*
* @since 2.0
* @see Control#moveAbove
* @see Control#setFocus
* @see Control#setVisible
* @see Display#getActiveShell
* @see Decorations#setDefaultButton(Button)
* @see Shell#open
* @see Shell#setActive
*/
public void forceActive () {
checkWidget ();
bringToTop (true);
}
代码示例来源:origin: org.eclipse.platform/org.eclipse.swt.gtk.aix.ppc
/**
* If the receiver is visible, moves it to the top of the
* drawing order for the display on which it was created
* (so that all other shells on that display, which are not
* the receiver's children will be drawn behind it) and asks
* the window manager to make the shell active
*
* @exception SWTException <ul>
* <li>ERROR_WIDGET_DISPOSED - if the receiver has been disposed</li>
* <li>ERROR_THREAD_INVALID_ACCESS - if not called from the thread that created the receiver</li>
* </ul>
*
* @since 2.0
* @see Control#moveAbove
* @see Control#setFocus
* @see Control#setVisible
* @see Display#getActiveShell
* @see Decorations#setDefaultButton(Button)
* @see Shell#open
* @see Shell#setActive
*/
public void setActive () {
checkWidget ();
bringToTop (false);
}
代码示例来源:origin: org.eclipse.platform/org.eclipse.swt.gtk.aix.ppc
/**
* If the receiver is visible, moves it to the top of the
* drawing order for the display on which it was created
* (so that all other shells on that display, which are not
* the receiver's children will be drawn behind it) and forces
* the window manager to make the shell active.
*
* @exception SWTException <ul>
* <li>ERROR_WIDGET_DISPOSED - if the receiver has been disposed</li>
* <li>ERROR_THREAD_INVALID_ACCESS - if not called from the thread that created the receiver</li>
* </ul>
*
* @since 2.0
* @see Control#moveAbove
* @see Control#setFocus
* @see Control#setVisible
* @see Display#getActiveShell
* @see Decorations#setDefaultButton(Button)
* @see Shell#open
* @see Shell#setActive
*/
public void forceActive () {
checkWidget ();
bringToTop (true);
}
代码示例来源:origin: org.eclipse.platform/org.eclipse.swt.gtk.linux.ppc
/**
* If the receiver is visible, moves it to the top of the
* drawing order for the display on which it was created
* (so that all other shells on that display, which are not
* the receiver's children will be drawn behind it) and asks
* the window manager to make the shell active
*
* @exception SWTException <ul>
* <li>ERROR_WIDGET_DISPOSED - if the receiver has been disposed</li>
* <li>ERROR_THREAD_INVALID_ACCESS - if not called from the thread that created the receiver</li>
* </ul>
*
* @since 2.0
* @see Control#moveAbove
* @see Control#setFocus
* @see Control#setVisible
* @see Display#getActiveShell
* @see Decorations#setDefaultButton(Button)
* @see Shell#open
* @see Shell#setActive
*/
public void setActive () {
checkWidget ();
bringToTop (false);
}
代码示例来源:origin: org.eclipse.platform/org.eclipse.swt.gtk.linux.ppc
/**
* If the receiver is visible, moves it to the top of the
* drawing order for the display on which it was created
* (so that all other shells on that display, which are not
* the receiver's children will be drawn behind it) and forces
* the window manager to make the shell active.
*
* @exception SWTException <ul>
* <li>ERROR_WIDGET_DISPOSED - if the receiver has been disposed</li>
* <li>ERROR_THREAD_INVALID_ACCESS - if not called from the thread that created the receiver</li>
* </ul>
*
* @since 2.0
* @see Control#moveAbove
* @see Control#setFocus
* @see Control#setVisible
* @see Display#getActiveShell
* @see Decorations#setDefaultButton(Button)
* @see Shell#open
* @see Shell#setActive
*/
public void forceActive () {
checkWidget ();
bringToTop (true);
}
代码示例来源:origin: org.eclipse.platform/org.eclipse.swt.gtk.linux.s390x
/**
* If the receiver is visible, moves it to the top of the
* drawing order for the display on which it was created
* (so that all other shells on that display, which are not
* the receiver's children will be drawn behind it) and asks
* the window manager to make the shell active
*
* @exception SWTException <ul>
* <li>ERROR_WIDGET_DISPOSED - if the receiver has been disposed</li>
* <li>ERROR_THREAD_INVALID_ACCESS - if not called from the thread that created the receiver</li>
* </ul>
*
* @since 2.0
* @see Control#moveAbove
* @see Control#setFocus
* @see Control#setVisible
* @see Display#getActiveShell
* @see Decorations#setDefaultButton(Button)
* @see Shell#open
* @see Shell#setActive
*/
public void setActive () {
checkWidget ();
bringToTop (false);
}
代码示例来源:origin: org.eclipse.scout.sdk.deps/org.eclipse.swt.win32.win32.x86
/**
* If the receiver is visible, moves it to the top of the
* drawing order for the display on which it was created
* (so that all other shells on that display, which are not
* the receiver's children will be drawn behind it) and asks
* the window manager to make the shell active
*
* @exception SWTException <ul>
* <li>ERROR_WIDGET_DISPOSED - if the receiver has been disposed</li>
* <li>ERROR_THREAD_INVALID_ACCESS - if not called from the thread that created the receiver</li>
* </ul>
*
* @since 2.0
* @see Control#moveAbove
* @see Control#setFocus
* @see Control#setVisible
* @see Display#getActiveShell
* @see Decorations#setDefaultButton(Button)
* @see Shell#open
* @see Shell#setActive
*/
public void setActive () {
checkWidget ();
if (!isVisible ()) return;
bringToTop ();
// widget could be disposed at this point
}
代码示例来源:origin: org.eclipse.platform/org.eclipse.swt.gtk.aix.ppc
@Override
public void setMinimized (boolean minimized) {
checkWidget();
if (this.minimized == minimized) return;
super.setMinimized (minimized);
if (minimized) {
OS.gtk_window_iconify (shellHandle);
} else {
OS.gtk_window_deiconify (shellHandle);
bringToTop (false);
}
}
代码示例来源:origin: org.eclipse.platform/org.eclipse.swt.gtk.linux.ppc
@Override
public void setMinimized (boolean minimized) {
checkWidget();
if (this.minimized == minimized) return;
super.setMinimized (minimized);
if (minimized) {
OS.gtk_window_iconify (shellHandle);
} else {
OS.gtk_window_deiconify (shellHandle);
bringToTop (false);
}
}
代码示例来源:origin: org.eclipse.platform/org.eclipse.swt.gtk.linux.s390x
@Override
public void setMinimized (boolean minimized) {
checkWidget();
if (this.minimized == minimized) return;
super.setMinimized (minimized);
if (minimized) {
OS.gtk_window_iconify (shellHandle);
} else {
OS.gtk_window_deiconify (shellHandle);
bringToTop (false);
}
}
代码示例来源:origin: org.eclipse.platform/org.eclipse.swt.gtk.linux.ppc
void fixActiveShell () {
if (display.activeShell == this) {
Shell shell = null;
if (parent != null && parent.isVisible ()) shell = parent.getShell ();
if (shell == null && isUndecorated ()) {
Shell [] shells = display.getShells ();
for (int i = 0; i < shells.length; i++) {
if (shells [i] != null && shells [i].isVisible ()) {
shell = shells [i];
break;
}
}
}
if (shell != null) shell.bringToTop (false);
}
}
代码示例来源:origin: org.eclipse.platform/org.eclipse.swt.gtk.linux.s390x
void fixActiveShell () {
if (display.activeShell == this) {
Shell shell = null;
if (parent != null && parent.isVisible ()) shell = parent.getShell ();
if (shell == null && isUndecorated ()) {
Shell [] shells = display.getShells ();
for (int i = 0; i < shells.length; i++) {
if (shells [i] != null && shells [i].isVisible ()) {
shell = shells [i];
break;
}
}
}
if (shell != null) shell.bringToTop (false);
}
}
代码示例来源:origin: org.eclipse.platform/org.eclipse.swt.gtk.aix.ppc
void fixActiveShell () {
if (display.activeShell == this) {
Shell shell = null;
if (parent != null && parent.isVisible ()) shell = parent.getShell ();
if (shell == null && isUndecorated ()) {
Shell [] shells = display.getShells ();
for (int i = 0; i < shells.length; i++) {
if (shells [i] != null && shells [i].isVisible ()) {
shell = shells [i];
break;
}
}
}
if (shell != null) shell.bringToTop (false);
}
}
代码示例来源:origin: org.eclipse.rap/org.eclipse.rap.rwt
bringToTop();
setVisible( true );
if( !restoreFocus() && !traverseGroup( true ) ) {
代码示例来源:origin: org.eclipse.platform/org.eclipse.swt.gtk.linux.s390x
/**
* Forces the receiver to have the <em>keyboard focus</em>, causing
* all keyboard events to be delivered to it.
*
* @return <code>true</code> if the control got focus, and <code>false</code> if it was unable to.
*
* @exception SWTException <ul>
* <li>ERROR_WIDGET_DISPOSED - if the receiver has been disposed</li>
* <li>ERROR_THREAD_INVALID_ACCESS - if not called from the thread that created the receiver</li>
* </ul>
*
* @see #setFocus
*/
public boolean forceFocus () {
checkWidget();
if (display.focusEvent == SWT.FocusOut) return false;
Shell shell = getShell ();
shell.setSavedFocus (this);
if (!isEnabled () || !isVisible ()) return false;
shell.bringToTop (false);
return forceFocus (focusHandle ());
}
代码示例来源:origin: org.eclipse.platform/org.eclipse.swt.gtk.aix.ppc
/**
* Forces the receiver to have the <em>keyboard focus</em>, causing
* all keyboard events to be delivered to it.
*
* @return <code>true</code> if the control got focus, and <code>false</code> if it was unable to.
*
* @exception SWTException <ul>
* <li>ERROR_WIDGET_DISPOSED - if the receiver has been disposed</li>
* <li>ERROR_THREAD_INVALID_ACCESS - if not called from the thread that created the receiver</li>
* </ul>
*
* @see #setFocus
*/
public boolean forceFocus () {
checkWidget();
if (display.focusEvent == SWT.FocusOut) return false;
Shell shell = getShell ();
shell.setSavedFocus (this);
if (!isEnabled () || !isVisible ()) return false;
shell.bringToTop (false);
return forceFocus (focusHandle ());
}
代码示例来源:origin: org.eclipse.platform/org.eclipse.swt.gtk.linux.ppc
/**
* Forces the receiver to have the <em>keyboard focus</em>, causing
* all keyboard events to be delivered to it.
*
* @return <code>true</code> if the control got focus, and <code>false</code> if it was unable to.
*
* @exception SWTException <ul>
* <li>ERROR_WIDGET_DISPOSED - if the receiver has been disposed</li>
* <li>ERROR_THREAD_INVALID_ACCESS - if not called from the thread that created the receiver</li>
* </ul>
*
* @see #setFocus
*/
public boolean forceFocus () {
checkWidget();
if (display.focusEvent == SWT.FocusOut) return false;
Shell shell = getShell ();
shell.setSavedFocus (this);
if (!isEnabled () || !isVisible ()) return false;
shell.bringToTop (false);
return forceFocus (focusHandle ());
}
代码示例来源:origin: org.eclipse.platform/org.eclipse.swt.gtk.linux.s390x
bringToTop (false);
if (Shell.class.isInstance(getParent()) && !getParent().isVisible())
Shell.class.cast(getParent()).open();
代码示例来源:origin: org.eclipse.platform/org.eclipse.swt.gtk.aix.ppc
bringToTop (false);
if (Shell.class.isInstance(getParent()) && !getParent().isVisible())
Shell.class.cast(getParent()).open();
代码示例来源:origin: org.eclipse.swt.cocoa.macosx/x86_64
updateModal ();
bringToTop (false);
setWindowVisible (true, true);
if (isDisposed ()) return;
内容来源于网络,如有侵权,请联系作者删除!