Remove UserAgent class. Use mootools.
This commit is contained in:
@@ -159,7 +159,7 @@ mindplot.MindmapDesigner = new Class({
|
||||
var selectableObjects = this.getSelectedObjects();
|
||||
|
||||
// Disable all nodes on focus but not the current if Ctrl key isn't being pressed
|
||||
if (!$defined(event) || event.ctrlKey == false) {
|
||||
if (!$defined(event) || (event.ctrlKey == false && event.metaKey == false)) {
|
||||
selectableObjects.forEach(function(selectableObject) {
|
||||
if (selectableObject.isOnFocus() && selectableObject != currentObject) {
|
||||
selectableObject.setOnFocus(false);
|
||||
@@ -333,7 +333,7 @@ mindplot.MindmapDesigner = new Class({
|
||||
this._actionRunner.markAsChangeBase();
|
||||
},
|
||||
|
||||
loadFromCollaborativeModel: function(collaborationManager){
|
||||
loadFromCollaborativeModel: function(collaborationManager) {
|
||||
var mindmap = collaborationManager.buildWiseModel();
|
||||
this._loadMap(1, mindmap);
|
||||
|
||||
@@ -745,7 +745,7 @@ mindplot.MindmapDesigner = new Class({
|
||||
dialog.adopt(msg).show();
|
||||
|
||||
// IE doesn't like too much this focus action...
|
||||
if (!core.UserAgent.isIE()) {
|
||||
if (!Browser.ie) {
|
||||
urlInput.focus();
|
||||
}
|
||||
}
|
||||
|
@@ -171,7 +171,7 @@ mindplot.Workspace = new Class({
|
||||
workspace.setCoordOrigin(coordOriginX, coordOriginY);
|
||||
|
||||
// Change cursor.
|
||||
if (core.UserAgent.isMozillaFamily()) {
|
||||
if (Browser.firefox) {
|
||||
window.document.body.style.cursor = "-moz-grabbing";
|
||||
} else {
|
||||
window.document.body.style.cursor = "move";
|
||||
|
@@ -98,7 +98,7 @@ TestCase("Mindplot test",{
|
||||
|
||||
var fireNativeEvent = function(type, target, position){
|
||||
var event;
|
||||
if(core.UserAgent.isIE()){
|
||||
if(Browser.ie){
|
||||
event = document.createEventObject();
|
||||
event.screenX = position.x;
|
||||
event.screenY = position.y;
|
||||
|
@@ -24,7 +24,7 @@
|
||||
console.log("value:" + value);
|
||||
}
|
||||
};
|
||||
var palette = new mindplot.widget.ColorPalette('myButton', model,"/mindplot/src/main/javascript/widget");
|
||||
var palette = new mindplot.widget.ColorPalettePanel('myButton', model,"/mindplot/src/main/javascript/widget");
|
||||
});
|
||||
|
||||
</script>
|
||||
|
Reference in New Issue
Block a user