|
|
Ext.window Namespace
Download SDK: SharpKit.ExtJs.zip
Classes
|
MessageBox
|
Utility class for generating different styles of message boxes. The singleton instance, Ext.Msg can also be used.
Note that a MessageBox is asynchronous. Unlike a regular JavaScript alert (which will halt
browser execution), showing a MessageBox will not cause the code to stop. For this reason, if you have code
that should only run after some user feedback from the MessageBox, you must use a callback function
(see the function parameter for show for more details). Example usage: // Basic alert:
Ext.Msg.alert('Status', 'Changes saved successfully.');
// Prompt for user data and process the result using a callback:
Ext.Msg.prompt('Name', 'Please enter your name:', function(btn, text){
if (btn == 'ok'){
// process text value and close...
}
});
// Show a dialog using config options:
Ext.Msg.show({
title:'Save Changes?',
msg: 'You are closing a tab that has unsaved changes. Would you like to save your changes?',
buttons: Ext.Msg.YESNOCANCEL,
fn: processResult,
animateTarget: 'elId',
icon: Ext.window.MessageBox.QUESTION
});
|
|
MessageBoxConfig
|
|
|
MessageBoxEvents
|
|
|
Window
|
A specialized panel intended for use as an application window. Windows are floated, resizable, and
draggable by default. Windows can be maximized to fill the viewport,
restored to their prior size, and can be minimized. Windows can also be linked to a Ext.ZIndexManager or managed by the Ext.WindowManager to provide
grouping, activation, to front, to back and other application-specific behavior. By default, Windows will be rendered to document.body. To constrain a Window to another element
specify renderTo. As with all Containers, it is important to consider how you want the Window
to size and arrange any child Components. Choose an appropriate layout configuration which lays out
child Components in the required manner.
Example: Ext.create('Ext.window.Window', {
title: 'Hello',
height: 200,
width: 400,
layout: 'fit',
items: { // Let's put an empty grid in just to illustrate fit layout
xtype: 'grid',
border: false,
columns: [{header: 'World'}], // One header just for show. There's no data,
store: Ext.create('Ext.data.ArrayStore', {}) // A dummy empty data store
}
}).show();
|
|
WindowConfig
|
|
|
WindowEvents
|
|
|