Átállás
JUSTWEB létrehozása
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
/* Layout */
|
||||
/* Layout */
|
||||
|
||||
.navbar-layout,
|
||||
.navbar-layout-tablet {
|
||||
@@ -94,13 +94,16 @@
|
||||
}
|
||||
|
||||
.dx-theme-android5 .navbar-layout .layout-footer {
|
||||
bottom: 0;
|
||||
height: 56px;
|
||||
display: none;
|
||||
bottom: -9999px;
|
||||
left: -9999px;
|
||||
visibility: hidden;
|
||||
}
|
||||
|
||||
.dx-theme-android5 .navbar-layout.has-toolbar .layout-footer {
|
||||
display: block;
|
||||
bottom: 0;
|
||||
left: 0;
|
||||
visibility: visible;
|
||||
}
|
||||
|
||||
/* win8 */
|
||||
@@ -251,7 +254,7 @@
|
||||
bottom: 68px;
|
||||
}
|
||||
|
||||
.dx-theme-generic .navbar-layout .layout-footer,
|
||||
.dx-theme-generic .navbar-layout .layout-footer,
|
||||
.dx-theme-generic .navbar-layout .layout-footer .dx-navbar {
|
||||
bottom: 0;
|
||||
height: 68px;
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
<div class="navbar-layout" data-options="dxLayout : { name: 'navbar', platform: 'ios' } ">
|
||||
<div class="navbar-layout" data-options="dxLayout : { name: 'navbar', platform: 'ios' } ">
|
||||
<div class="layout-header dx-toolbar-background" data-options="dxContentPlaceholder : { name: 'header', animation: 'view-header-toolbar' }">
|
||||
<div data-bind="dxToolbar: { items: [ { text: title, location: 'center' } ] }" data-options="dxCommandContainer : { id: 'ios-header-toolbar' }">
|
||||
</div>
|
||||
|
||||
@@ -1,63 +1,99 @@
|
||||
"use strict";
|
||||
(function(root, factory) {
|
||||
/* global define, DevExpress */
|
||||
if (typeof define === 'function' && define.amd) {
|
||||
define(function(require, exports, module) {
|
||||
module.exports = factory(require("framework/html/presets").layoutSets, require("framework/html/layout_controller").DefaultLayoutController, require("ui/toolbar"))
|
||||
})
|
||||
}
|
||||
else {
|
||||
module.exports = factory(
|
||||
require("framework/html/presets").layoutSets,
|
||||
require("framework/html/layout_controller").DefaultLayoutController,
|
||||
|
||||
require("ui/toolbar")
|
||||
);
|
||||
});
|
||||
} else {
|
||||
root.DevExpress.layouts = root.DevExpress.layouts || {};
|
||||
root.DevExpress.layouts.NavbarLayout = factory(DevExpress.framework.html.layoutSets, DevExpress.framework.html.DefaultLayoutController);
|
||||
root.DevExpress.framework.html.NavBarController = root.DevExpress.layouts.NavbarLayout.NavBarController
|
||||
root.DevExpress.layouts.NavbarLayout = factory(
|
||||
DevExpress.framework.html.layoutSets,
|
||||
DevExpress.framework.html.DefaultLayoutController
|
||||
);
|
||||
root.DevExpress.framework.html.NavBarController = root.DevExpress.layouts.NavbarLayout.NavBarController;
|
||||
}
|
||||
}(this, function(layoutSets, DefaultLayoutController) {
|
||||
}(window, function(layoutSets, DefaultLayoutController) {
|
||||
|
||||
var exports = {},
|
||||
HAS_NAVBAR_CLASS = "has-navbar",
|
||||
HAS_TOOLBAR_CLASS = "has-toolbar",
|
||||
|
||||
LAYOUT_FOOTER_SELECTOR = ".layout-footer",
|
||||
ACTIVE_TOOLBAR_SELECTOR = ".dx-active-view .dx-toolbar";
|
||||
|
||||
var NavBarController = DefaultLayoutController.inherit({
|
||||
ctor: function(options) {
|
||||
options = options || {};
|
||||
options.name = options.name || "navbar";
|
||||
this.callBase(options)
|
||||
}, _createNavigationWidget: function(navigationCommands) {
|
||||
this.callBase(navigationCommands);
|
||||
this.$navbar = this._$mainLayout.find(".navbar-container");
|
||||
return this.$navbar
|
||||
}, _renderNavigationImpl: function(navigationCommands) {
|
||||
this.callBase(navigationCommands);
|
||||
if (navigationCommands.length) {
|
||||
this._$mainLayout.addClass(HAS_NAVBAR_CLASS)
|
||||
}
|
||||
}, _showViewImpl: function(viewInfo) {
|
||||
var that = this;
|
||||
return that.callBase.apply(that, arguments).done(function() {
|
||||
var $toolbar = that._$mainLayout.find(LAYOUT_FOOTER_SELECTOR).find(ACTIVE_TOOLBAR_SELECTOR),
|
||||
isToolbarEmpty = !$toolbar.length || !$toolbar.dxToolbar("instance").option("visible");
|
||||
that._$mainLayout.toggleClass(HAS_TOOLBAR_CLASS, !isToolbarEmpty)
|
||||
})
|
||||
}
|
||||
});
|
||||
|
||||
ctor: function(options) {
|
||||
options = options || {};
|
||||
options.name = options.name || "navbar";
|
||||
this.callBase(options);
|
||||
},
|
||||
|
||||
_createNavigationWidget: function(navigationCommands) {
|
||||
this.callBase(navigationCommands);
|
||||
this.$navbar = this._$mainLayout.find(".navbar-container");
|
||||
return this.$navbar;
|
||||
},
|
||||
|
||||
_renderNavigationImpl: function(navigationCommands) {
|
||||
this.callBase(navigationCommands);
|
||||
if (navigationCommands.length) {
|
||||
this._$mainLayout.addClass(HAS_NAVBAR_CLASS);
|
||||
}
|
||||
},
|
||||
|
||||
_showViewImpl: function(viewInfo) {
|
||||
var that = this;
|
||||
|
||||
return that.callBase.apply(that, arguments).done(function() {
|
||||
var $toolbar = that._$mainLayout.find(LAYOUT_FOOTER_SELECTOR).find(ACTIVE_TOOLBAR_SELECTOR),
|
||||
isToolbarEmpty = !$toolbar.length || !$toolbar.dxToolbar("instance").option("visible");
|
||||
|
||||
that._$mainLayout.toggleClass(HAS_TOOLBAR_CLASS, !isToolbarEmpty);
|
||||
});
|
||||
}
|
||||
});
|
||||
|
||||
layoutSets["navbar"] = layoutSets["navbar"] || [];
|
||||
layoutSets["navbar"].push({
|
||||
platform: "ios", controller: new NavBarController
|
||||
platform: "ios",
|
||||
controller: new NavBarController()
|
||||
});
|
||||
layoutSets["navbar"].push({
|
||||
platform: "android", controller: new NavBarController
|
||||
platform: "android",
|
||||
controller: new NavBarController()
|
||||
});
|
||||
layoutSets["navbar"].push({
|
||||
platform: "generic", controller: new NavBarController
|
||||
platform: "generic",
|
||||
controller: new NavBarController()
|
||||
});
|
||||
layoutSets["navbar"].push({
|
||||
platform: "win", controller: new NavBarController
|
||||
platform: "win",
|
||||
controller: new NavBarController()
|
||||
});
|
||||
|
||||
layoutSets["split"] = layoutSets["split"] || [];
|
||||
layoutSets["split"].push({
|
||||
platform: "win", phone: false, root: true, pane: "master", controller: new NavBarController
|
||||
platform: "win",
|
||||
phone: false,
|
||||
root: true,
|
||||
pane: "master",
|
||||
controller: new NavBarController()
|
||||
});
|
||||
layoutSets["split"].push({
|
||||
platform: "win", phone: true, controller: new NavBarController
|
||||
platform: "win",
|
||||
phone: true,
|
||||
controller: new NavBarController()
|
||||
});
|
||||
|
||||
exports.NavBarController = NavBarController;
|
||||
return exports
|
||||
|
||||
return exports;
|
||||
|
||||
}));
|
||||
Reference in New Issue
Block a user