All Downloads are FREE. Search and download functionalities are using the official Maven repository.

system.windows.Window Maven / Gradle / Ivy

/*
 *  MIT License
 *
 *  Copyright (c) 2024 MASES s.r.l.
 *
 *  Permission is hereby granted, free of charge, to any person obtaining a copy
 *  of this software and associated documentation files (the "Software"), to deal
 *  in the Software without restriction, including without limitation the rights
 *  to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
 *  copies of the Software, and to permit persons to whom the Software is
 *  furnished to do so, subject to the following conditions:
 *
 *  The above copyright notice and this permission notice shall be included in all
 *  copies or substantial portions of the Software.
 *
 *  THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
 *  IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
 *  FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
 *  AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
 *  LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
 *  OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
 *  SOFTWARE.
 */

/**************************************************************************************
 * 
 *      This code was generated from a template using JCOReflector v. 1.14.0.0
 * 
 *      Manual changes to this file may cause unexpected behavior in your application.
 *      Manual changes to this file will be overwritten if the code is regenerated.
 * 
 *************************************************************************************/

package system.windows;

import org.mases.jcobridge.*;
import org.mases.jcobridge.netreflection.*;
import java.util.ArrayList;

// Import section
import system.windows.controls.ContentControl;
import system.windows.Window;
import system.windows.DependencyObject;
import system.windows.media.ImageSource;
import system.windows.Rect;
import system.windows.ResizeMode;
import system.windows.shell.TaskbarItemInfo;
import system.windows.SizeToContent;
import system.windows.WindowCollection;
import system.windows.WindowStartupLocation;
import system.windows.WindowState;
import system.windows.WindowStyle;
import system.componentmodel.CancelEventHandler;
import system.EventHandler;
import system.windows.DpiChangedEventHandler;


/**
 * The base .NET class managing System.Windows.Window, PresentationFramework, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35.
 * 

* * .NET documentation at https://docs.microsoft.com/en-us/dotnet/api/System.Windows.Window *

* * Powered by JCOBridge: more info at https://www.jcobridge.com * * @author MASES s.r.l https://masesgroup.com * @version 1.14.0.0 */ public class Window extends ContentControl { /** * Fully assembly qualified name: PresentationFramework, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35 */ public static final String assemblyFullName = "PresentationFramework, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35"; /** * Assembly name: PresentationFramework */ public static final String assemblyShortName = "PresentationFramework"; /** * Qualified class name: System.Windows.Window */ public static final String className = "System.Windows.Window"; static JCOBridge bridge = JCOBridgeInstance.getInstance(assemblyFullName); /** * The type managed from JCOBridge. See {@link JCType} */ public static JCType classType = createType(); static JCEnum enumInstance = null; JCObject classInstance = null; static JCType createType() { try { String classToCreate = className + ", " + (JCOReflector.getUseFullAssemblyName() ? assemblyFullName : assemblyShortName); if (JCOReflector.getDebug()) JCOReflector.writeLog("Creating %s", classToCreate); JCType typeCreated = bridge.GetType(classToCreate); if (JCOReflector.getDebug()) JCOReflector.writeLog("Created: %s", (typeCreated != null) ? typeCreated.toString() : "Returned null value"); return typeCreated; } catch (JCException e) { JCOReflector.writeLog(e); return null; } } void addReference(String ref) throws Throwable { try { bridge.AddReference(ref); } catch (JCNativeException jcne) { throw translateException(jcne); } } /** * Internal constructor. Use with caution */ public Window(java.lang.Object instance) throws Throwable { super(instance); if (instance instanceof JCObject) { classInstance = (JCObject) instance; } else throw new Exception("Cannot manage object, it is not a JCObject"); } public String getJCOAssemblyName() { return assemblyFullName; } public String getJCOClassName() { return className; } public String getJCOObjectName() { return className + ", " + (JCOReflector.getUseFullAssemblyName() ? assemblyFullName : assemblyShortName); } public java.lang.Object getJCOInstance() { return classInstance; } public void setJCOInstance(JCObject instance) { classInstance = instance; super.setJCOInstance(classInstance); } public JCType getJCOType() { return classType; } /** * Try to cast the {@link IJCOBridgeReflected} instance into {@link Window}, a cast assert is made to check if types are compatible. * @param from {@link IJCOBridgeReflected} instance to be casted * @return {@link Window} instance * @throws java.lang.Throwable in case of error during cast operation */ public static Window cast(IJCOBridgeReflected from) throws Throwable { NetType.AssertCast(classType, from); return new Window(from.getJCOInstance()); } // Constructors section public Window() throws Throwable, system.ArgumentException, system.ArgumentOutOfRangeException, system.NotImplementedException, system.ArgumentNullException, system.InvalidOperationException, system.resources.MissingManifestResourceException { try { // add reference to assemblyName.dll file addReference(JCOReflector.getUseFullAssemblyName() ? assemblyFullName : assemblyShortName); setJCOInstance((JCObject)classType.NewObject()); } catch (JCNativeException jcne) { throw translateException(jcne); } } // Methods section public boolean Activate() throws Throwable, system.ArgumentNullException, system.ArgumentException, system.ArgumentOutOfRangeException, system.FormatException, system.resources.MissingManifestResourceException, system.NotImplementedException, system.ObjectDisposedException, system.InvalidOperationException { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { return (boolean)classInstance.Invoke("Activate"); } catch (JCNativeException jcne) { throw translateException(jcne); } } public static Window GetWindow(DependencyObject dependencyObject) throws Throwable, system.ArgumentNullException, system.resources.MissingManifestResourceException, system.NotImplementedException, system.ArgumentException, system.ObjectDisposedException, system.InvalidOperationException, system.ArgumentOutOfRangeException, system.NotSupportedException { if (classType == null) throw new UnsupportedOperationException("classType is null."); try { JCObject objGetWindow = (JCObject)classType.Invoke("GetWindow", dependencyObject == null ? null : dependencyObject.getJCOInstance()); return new Window(objGetWindow); } catch (JCNativeException jcne) { throw translateException(jcne); } } public void Close() throws Throwable, system.ArgumentNullException, system.ArgumentException, system.ArgumentOutOfRangeException, system.FormatException, system.resources.MissingManifestResourceException, system.NotImplementedException, system.ObjectDisposedException, system.InvalidOperationException, system.RankException, system.componentmodel.InvalidEnumArgumentException, system.componentmodel.Win32Exception { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { classInstance.Invoke("Close"); } catch (JCNativeException jcne) { throw translateException(jcne); } } public void DragMove() throws Throwable, system.ArgumentNullException, system.ArgumentException, system.ArgumentOutOfRangeException, system.FormatException, system.resources.MissingManifestResourceException, system.NotImplementedException, system.ObjectDisposedException, system.InvalidOperationException, system.componentmodel.InvalidEnumArgumentException, system.componentmodel.Win32Exception, system.OverflowException { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { classInstance.Invoke("DragMove"); } catch (JCNativeException jcne) { throw translateException(jcne); } } public void Hide() throws Throwable, system.ArgumentNullException, system.resources.MissingManifestResourceException, system.NotImplementedException, system.ArgumentException, system.ObjectDisposedException, system.InvalidOperationException, system.ArgumentOutOfRangeException, system.NotSupportedException, system.componentmodel.Win32Exception, system.OverflowException, system.componentmodel.InvalidEnumArgumentException, system.threading.ThreadStateException, system.NullReferenceException, system.security.SecurityException, system.io.IOException { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { classInstance.Invoke("Hide"); } catch (JCNativeException jcne) { throw translateException(jcne); } } public void Show() throws Throwable, system.ArgumentNullException, system.resources.MissingManifestResourceException, system.NotImplementedException, system.ArgumentException, system.ObjectDisposedException, system.InvalidOperationException, system.ArgumentOutOfRangeException, system.NotSupportedException, system.componentmodel.Win32Exception, system.OverflowException, system.componentmodel.InvalidEnumArgumentException, system.threading.ThreadStateException, system.NullReferenceException, system.security.SecurityException, system.io.IOException { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { classInstance.Invoke("Show"); } catch (JCNativeException jcne) { throw translateException(jcne); } } // Properties section public boolean getAllowsTransparency() throws Throwable, system.ArgumentNullException, system.resources.MissingManifestResourceException, system.NotImplementedException, system.ArgumentException, system.ObjectDisposedException, system.InvalidOperationException, system.ArgumentOutOfRangeException, system.NotSupportedException { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { return (boolean)classInstance.Get("AllowsTransparency"); } catch (JCNativeException jcne) { throw translateException(jcne); } } public void setAllowsTransparency(boolean AllowsTransparency) throws Throwable, system.ArgumentNullException, system.resources.MissingManifestResourceException, system.NotImplementedException, system.ArgumentException, system.ObjectDisposedException, system.InvalidOperationException, system.ArgumentOutOfRangeException, system.NotSupportedException { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { classInstance.Set("AllowsTransparency", AllowsTransparency); } catch (JCNativeException jcne) { throw translateException(jcne); } } public boolean getIsActive() throws Throwable, system.ArgumentNullException, system.resources.MissingManifestResourceException, system.NotImplementedException, system.ArgumentException, system.ObjectDisposedException, system.InvalidOperationException, system.ArgumentOutOfRangeException, system.NotSupportedException { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { return (boolean)classInstance.Get("IsActive"); } catch (JCNativeException jcne) { throw translateException(jcne); } } public boolean getShowActivated() throws Throwable, system.ArgumentNullException, system.resources.MissingManifestResourceException, system.NotImplementedException, system.ArgumentException, system.ObjectDisposedException, system.InvalidOperationException, system.ArgumentOutOfRangeException, system.NotSupportedException { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { return (boolean)classInstance.Get("ShowActivated"); } catch (JCNativeException jcne) { throw translateException(jcne); } } public void setShowActivated(boolean ShowActivated) throws Throwable, system.ArgumentNullException, system.resources.MissingManifestResourceException, system.NotImplementedException, system.ArgumentException, system.ObjectDisposedException, system.InvalidOperationException, system.ArgumentOutOfRangeException, system.NotSupportedException { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { classInstance.Set("ShowActivated", ShowActivated); } catch (JCNativeException jcne) { throw translateException(jcne); } } public boolean getShowInTaskbar() throws Throwable, system.ArgumentNullException, system.resources.MissingManifestResourceException, system.NotImplementedException, system.ArgumentException, system.ObjectDisposedException, system.InvalidOperationException, system.ArgumentOutOfRangeException, system.NotSupportedException { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { return (boolean)classInstance.Get("ShowInTaskbar"); } catch (JCNativeException jcne) { throw translateException(jcne); } } public void setShowInTaskbar(boolean ShowInTaskbar) throws Throwable, system.ArgumentNullException, system.resources.MissingManifestResourceException, system.NotImplementedException, system.ArgumentException, system.ObjectDisposedException, system.InvalidOperationException, system.ArgumentOutOfRangeException, system.NotSupportedException { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { classInstance.Set("ShowInTaskbar", ShowInTaskbar); } catch (JCNativeException jcne) { throw translateException(jcne); } } public boolean getTopmost() throws Throwable, system.ArgumentNullException, system.resources.MissingManifestResourceException, system.NotImplementedException, system.ArgumentException, system.ObjectDisposedException, system.InvalidOperationException, system.ArgumentOutOfRangeException, system.NotSupportedException { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { return (boolean)classInstance.Get("Topmost"); } catch (JCNativeException jcne) { throw translateException(jcne); } } public void setTopmost(boolean Topmost) throws Throwable, system.ArgumentNullException, system.resources.MissingManifestResourceException, system.NotImplementedException, system.ArgumentException, system.ObjectDisposedException, system.InvalidOperationException, system.ArgumentOutOfRangeException, system.NotSupportedException { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { classInstance.Set("Topmost", Topmost); } catch (JCNativeException jcne) { throw translateException(jcne); } } public double getLeft() throws Throwable, system.ArgumentNullException, system.resources.MissingManifestResourceException, system.NotImplementedException, system.ArgumentException, system.ObjectDisposedException, system.InvalidOperationException, system.ArgumentOutOfRangeException, system.NotSupportedException { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { return (double)classInstance.Get("Left"); } catch (JCNativeException jcne) { throw translateException(jcne); } } public void setLeft(double Left) throws Throwable, system.ArgumentNullException, system.resources.MissingManifestResourceException, system.NotImplementedException, system.ArgumentException, system.ObjectDisposedException, system.InvalidOperationException, system.ArgumentOutOfRangeException, system.NotSupportedException { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { classInstance.Set("Left", Left); } catch (JCNativeException jcne) { throw translateException(jcne); } } public double getTop() throws Throwable, system.ArgumentNullException, system.resources.MissingManifestResourceException, system.NotImplementedException, system.ArgumentException, system.ObjectDisposedException, system.InvalidOperationException, system.ArgumentOutOfRangeException, system.NotSupportedException { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { return (double)classInstance.Get("Top"); } catch (JCNativeException jcne) { throw translateException(jcne); } } public void setTop(double Top) throws Throwable, system.ArgumentNullException, system.resources.MissingManifestResourceException, system.NotImplementedException, system.ArgumentException, system.ObjectDisposedException, system.InvalidOperationException, system.ArgumentOutOfRangeException, system.NotSupportedException { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { classInstance.Set("Top", Top); } catch (JCNativeException jcne) { throw translateException(jcne); } } public java.lang.String getTitle() throws Throwable, system.ArgumentNullException, system.resources.MissingManifestResourceException, system.NotImplementedException, system.ArgumentException, system.ObjectDisposedException, system.InvalidOperationException, system.ArgumentOutOfRangeException, system.NotSupportedException { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { return (java.lang.String)classInstance.Get("Title"); } catch (JCNativeException jcne) { throw translateException(jcne); } } public void setTitle(java.lang.String Title) throws Throwable, system.ArgumentNullException, system.resources.MissingManifestResourceException, system.NotImplementedException, system.ArgumentException, system.ObjectDisposedException, system.InvalidOperationException, system.ArgumentOutOfRangeException, system.NotSupportedException { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { classInstance.Set("Title", Title); } catch (JCNativeException jcne) { throw translateException(jcne); } } public ImageSource getIcon() throws Throwable, system.ArgumentNullException, system.resources.MissingManifestResourceException, system.NotImplementedException, system.ArgumentException, system.ObjectDisposedException, system.InvalidOperationException, system.ArgumentOutOfRangeException, system.NotSupportedException { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { JCObject val = (JCObject)classInstance.Get("Icon"); return new ImageSource(val); } catch (JCNativeException jcne) { throw translateException(jcne); } } public void setIcon(ImageSource Icon) throws Throwable, system.ArgumentNullException, system.ArgumentException, system.ArgumentOutOfRangeException, system.FormatException, system.resources.MissingManifestResourceException, system.NotImplementedException, system.ObjectDisposedException, system.InvalidOperationException, system.NotSupportedException { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { classInstance.Set("Icon", Icon == null ? null : Icon.getJCOInstance()); } catch (JCNativeException jcne) { throw translateException(jcne); } } public Rect getRestoreBounds() throws Throwable, system.ArgumentNullException, system.resources.MissingManifestResourceException, system.NotImplementedException, system.ArgumentException, system.ObjectDisposedException, system.InvalidOperationException, system.ArgumentOutOfRangeException, system.IndexOutOfRangeException, system.componentmodel.Win32Exception, system.NotSupportedException, system.security.SecurityException, system.UnauthorizedAccessException, system.io.IOException { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { JCObject val = (JCObject)classInstance.Get("RestoreBounds"); return new Rect(val); } catch (JCNativeException jcne) { throw translateException(jcne); } } public ResizeMode getResizeMode() throws Throwable, system.ArgumentNullException, system.resources.MissingManifestResourceException, system.NotImplementedException, system.ArgumentException, system.ObjectDisposedException, system.InvalidOperationException, system.ArgumentOutOfRangeException, system.NotSupportedException { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { JCObject val = (JCObject)classInstance.Get("ResizeMode"); return new ResizeMode(val); } catch (JCNativeException jcne) { throw translateException(jcne); } } public void setResizeMode(ResizeMode ResizeMode) throws Throwable, system.ArgumentNullException, system.resources.MissingManifestResourceException, system.NotImplementedException, system.ArgumentException, system.ObjectDisposedException, system.InvalidOperationException, system.ArgumentOutOfRangeException, system.NotSupportedException { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { classInstance.Set("ResizeMode", ResizeMode == null ? null : ResizeMode.getJCOInstance()); } catch (JCNativeException jcne) { throw translateException(jcne); } } public TaskbarItemInfo getTaskbarItemInfo() throws Throwable, system.ArgumentNullException, system.resources.MissingManifestResourceException, system.NotImplementedException, system.ArgumentException, system.ObjectDisposedException, system.InvalidOperationException, system.ArgumentOutOfRangeException, system.NotSupportedException { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { JCObject val = (JCObject)classInstance.Get("TaskbarItemInfo"); return new TaskbarItemInfo(val); } catch (JCNativeException jcne) { throw translateException(jcne); } } public void setTaskbarItemInfo(TaskbarItemInfo TaskbarItemInfo) throws Throwable, system.ArgumentNullException, system.resources.MissingManifestResourceException, system.NotImplementedException, system.ArgumentException, system.ObjectDisposedException, system.InvalidOperationException, system.ArgumentOutOfRangeException, system.NotSupportedException { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { classInstance.Set("TaskbarItemInfo", TaskbarItemInfo == null ? null : TaskbarItemInfo.getJCOInstance()); } catch (JCNativeException jcne) { throw translateException(jcne); } } public SizeToContent getSizeToContent() throws Throwable, system.ArgumentNullException, system.resources.MissingManifestResourceException, system.NotImplementedException, system.ArgumentException, system.ObjectDisposedException, system.InvalidOperationException, system.ArgumentOutOfRangeException, system.NotSupportedException { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { JCObject val = (JCObject)classInstance.Get("SizeToContent"); return new SizeToContent(val); } catch (JCNativeException jcne) { throw translateException(jcne); } } public void setSizeToContent(SizeToContent SizeToContent) throws Throwable, system.ArgumentNullException, system.resources.MissingManifestResourceException, system.NotImplementedException, system.ArgumentException, system.ObjectDisposedException, system.InvalidOperationException, system.ArgumentOutOfRangeException, system.NotSupportedException { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { classInstance.Set("SizeToContent", SizeToContent == null ? null : SizeToContent.getJCOInstance()); } catch (JCNativeException jcne) { throw translateException(jcne); } } public Window getOwner() throws Throwable, system.ArgumentNullException, system.ArgumentException, system.ArgumentOutOfRangeException, system.FormatException, system.resources.MissingManifestResourceException, system.NotImplementedException, system.ObjectDisposedException, system.InvalidOperationException { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { JCObject val = (JCObject)classInstance.Get("Owner"); return new Window(val); } catch (JCNativeException jcne) { throw translateException(jcne); } } public void setOwner(Window Owner) throws Throwable, system.ArgumentNullException, system.ArgumentException, system.ArgumentOutOfRangeException, system.FormatException, system.resources.MissingManifestResourceException, system.NotImplementedException, system.ObjectDisposedException, system.InvalidOperationException, system.RankException, system.NotSupportedException, system.componentmodel.InvalidEnumArgumentException, system.componentmodel.Win32Exception, system.collections.generic.KeyNotFoundException, system.OutOfMemoryException, system.OverflowException, system.TimeoutException, system.security.SecurityException { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { classInstance.Set("Owner", Owner == null ? null : Owner.getJCOInstance()); } catch (JCNativeException jcne) { throw translateException(jcne); } } public WindowCollection getOwnedWindows() throws Throwable, system.ArgumentNullException, system.resources.MissingManifestResourceException, system.NotImplementedException, system.ArgumentException, system.ObjectDisposedException, system.InvalidOperationException, system.ArgumentOutOfRangeException { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { JCObject val = (JCObject)classInstance.Get("OwnedWindows"); return new WindowCollection(val); } catch (JCNativeException jcne) { throw translateException(jcne); } } public WindowStartupLocation getWindowStartupLocation() throws Throwable, system.ArgumentNullException, system.resources.MissingManifestResourceException, system.NotImplementedException, system.ArgumentException, system.ObjectDisposedException, system.InvalidOperationException { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { JCObject val = (JCObject)classInstance.Get("WindowStartupLocation"); return new WindowStartupLocation(val); } catch (JCNativeException jcne) { throw translateException(jcne); } } public void setWindowStartupLocation(WindowStartupLocation WindowStartupLocation) throws Throwable, system.ArgumentNullException, system.resources.MissingManifestResourceException, system.NotImplementedException, system.ArgumentException, system.ObjectDisposedException, system.InvalidOperationException, system.ArgumentOutOfRangeException, system.globalization.CultureNotFoundException, system.IndexOutOfRangeException, system.componentmodel.InvalidEnumArgumentException { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { classInstance.Set("WindowStartupLocation", WindowStartupLocation == null ? null : WindowStartupLocation.getJCOInstance()); } catch (JCNativeException jcne) { throw translateException(jcne); } } public WindowState getWindowState() throws Throwable, system.ArgumentNullException, system.resources.MissingManifestResourceException, system.NotImplementedException, system.ArgumentException, system.ObjectDisposedException, system.InvalidOperationException, system.ArgumentOutOfRangeException, system.NotSupportedException { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { JCObject val = (JCObject)classInstance.Get("WindowState"); return new WindowState(val); } catch (JCNativeException jcne) { throw translateException(jcne); } } public void setWindowState(WindowState WindowState) throws Throwable, system.ArgumentNullException, system.resources.MissingManifestResourceException, system.NotImplementedException, system.ArgumentException, system.ObjectDisposedException, system.InvalidOperationException, system.ArgumentOutOfRangeException, system.NotSupportedException { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { classInstance.Set("WindowState", WindowState == null ? null : WindowState.getJCOInstance()); } catch (JCNativeException jcne) { throw translateException(jcne); } } public WindowStyle getWindowStyle() throws Throwable, system.ArgumentNullException, system.resources.MissingManifestResourceException, system.NotImplementedException, system.ArgumentException, system.ObjectDisposedException, system.InvalidOperationException, system.ArgumentOutOfRangeException, system.NotSupportedException { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { JCObject val = (JCObject)classInstance.Get("WindowStyle"); return new WindowStyle(val); } catch (JCNativeException jcne) { throw translateException(jcne); } } public void setWindowStyle(WindowStyle WindowStyle) throws Throwable, system.ArgumentNullException, system.resources.MissingManifestResourceException, system.NotImplementedException, system.ArgumentException, system.ObjectDisposedException, system.InvalidOperationException, system.ArgumentOutOfRangeException, system.NotSupportedException { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { classInstance.Set("WindowStyle", WindowStyle == null ? null : WindowStyle.getJCOInstance()); } catch (JCNativeException jcne) { throw translateException(jcne); } } // Instance Events section public void addClosing(CancelEventHandler handler) throws Throwable { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { classInstance.RegisterEventListener("Closing", handler); } catch (JCNativeException jcne) { throw translateException(jcne); } } public void removeClosing(CancelEventHandler handler) throws Throwable { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { classInstance.UnregisterEventListener("Closing", handler); } catch (JCNativeException jcne) { throw translateException(jcne); } } public void addActivated(EventHandler handler) throws Throwable { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { classInstance.RegisterEventListener("Activated", handler); } catch (JCNativeException jcne) { throw translateException(jcne); } } public void removeActivated(EventHandler handler) throws Throwable { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { classInstance.UnregisterEventListener("Activated", handler); } catch (JCNativeException jcne) { throw translateException(jcne); } } public void addClosed(EventHandler handler) throws Throwable { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { classInstance.RegisterEventListener("Closed", handler); } catch (JCNativeException jcne) { throw translateException(jcne); } } public void removeClosed(EventHandler handler) throws Throwable { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { classInstance.UnregisterEventListener("Closed", handler); } catch (JCNativeException jcne) { throw translateException(jcne); } } public void addContentRendered(EventHandler handler) throws Throwable { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { classInstance.RegisterEventListener("ContentRendered", handler); } catch (JCNativeException jcne) { throw translateException(jcne); } } public void removeContentRendered(EventHandler handler) throws Throwable { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { classInstance.UnregisterEventListener("ContentRendered", handler); } catch (JCNativeException jcne) { throw translateException(jcne); } } public void addDeactivated(EventHandler handler) throws Throwable { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { classInstance.RegisterEventListener("Deactivated", handler); } catch (JCNativeException jcne) { throw translateException(jcne); } } public void removeDeactivated(EventHandler handler) throws Throwable { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { classInstance.UnregisterEventListener("Deactivated", handler); } catch (JCNativeException jcne) { throw translateException(jcne); } } public void addLocationChanged(EventHandler handler) throws Throwable { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { classInstance.RegisterEventListener("LocationChanged", handler); } catch (JCNativeException jcne) { throw translateException(jcne); } } public void removeLocationChanged(EventHandler handler) throws Throwable { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { classInstance.UnregisterEventListener("LocationChanged", handler); } catch (JCNativeException jcne) { throw translateException(jcne); } } public void addSourceInitialized(EventHandler handler) throws Throwable { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { classInstance.RegisterEventListener("SourceInitialized", handler); } catch (JCNativeException jcne) { throw translateException(jcne); } } public void removeSourceInitialized(EventHandler handler) throws Throwable { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { classInstance.UnregisterEventListener("SourceInitialized", handler); } catch (JCNativeException jcne) { throw translateException(jcne); } } public void addStateChanged(EventHandler handler) throws Throwable { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { classInstance.RegisterEventListener("StateChanged", handler); } catch (JCNativeException jcne) { throw translateException(jcne); } } public void removeStateChanged(EventHandler handler) throws Throwable { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { classInstance.UnregisterEventListener("StateChanged", handler); } catch (JCNativeException jcne) { throw translateException(jcne); } } public void addDpiChanged(DpiChangedEventHandler handler) throws Throwable { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { classInstance.RegisterEventListener("DpiChanged", handler); } catch (JCNativeException jcne) { throw translateException(jcne); } } public void removeDpiChanged(DpiChangedEventHandler handler) throws Throwable { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { classInstance.UnregisterEventListener("DpiChanged", handler); } catch (JCNativeException jcne) { throw translateException(jcne); } } }





© 2015 - 2024 Weber Informatics LLC | Privacy Policy