mirror of
https://github.com/abap2UI5/abap2UI5.git
synced 2025-04-30 04:36:18 +08:00
enable toggle debug popup (#1563)
This commit is contained in:
parent
ef50f709ce
commit
72798539a0
|
@ -37,7 +37,13 @@ sap.ui.define(["sap/ui/core/UIComponent", "z2ui5/model/models",
|
||||||
|
|
||||||
document.addEventListener("keydown", function (zEvent) {
|
document.addEventListener("keydown", function (zEvent) {
|
||||||
if (zEvent?.ctrlKey && zEvent?.key === "F12") {
|
if (zEvent?.ctrlKey && zEvent?.key === "F12") {
|
||||||
new z2ui5.cc.DebugTool().show();
|
if (!z2ui5.debugTool){
|
||||||
|
z2ui5.debugTool = new z2ui5.cc.DebugTool();
|
||||||
|
z2ui5.debugTool.show();
|
||||||
|
} else {
|
||||||
|
z2ui5.debugTool.close();
|
||||||
|
z2ui5.debugTool = null;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
|
|
@ -137,6 +137,13 @@ sap.ui.define(["sap/ui/core/Control", "sap/ui/core/Fragment", "sap/ui/model/json
|
||||||
this.oDialog.addStyleClass('dbg-ltr');
|
this.oDialog.addStyleClass('dbg-ltr');
|
||||||
this.oDialog.setModel(oModel);
|
this.oDialog.setModel(oModel);
|
||||||
this.oDialog.open();
|
this.oDialog.open();
|
||||||
|
},
|
||||||
|
|
||||||
|
async close(){
|
||||||
|
if (this.oDialog){
|
||||||
|
this.oDialog.close();
|
||||||
|
this.oDialog.destry();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
|
@ -57,7 +57,13 @@ CLASS z2ui5_cl_app_component_js IMPLEMENTATION.
|
||||||
`` && |\n| &&
|
`` && |\n| &&
|
||||||
` document.addEventListener("keydown", function (zEvent) {` && |\n| &&
|
` document.addEventListener("keydown", function (zEvent) {` && |\n| &&
|
||||||
` if (zEvent?.ctrlKey && zEvent?.key === "F12") {` && |\n| &&
|
` if (zEvent?.ctrlKey && zEvent?.key === "F12") {` && |\n| &&
|
||||||
` new z2ui5.cc.DebugTool().show();` && |\n| &&
|
` if (!z2ui5.debugTool){` && |\n| &&
|
||||||
|
` z2ui5.debugTool = new z2ui5.cc.DebugTool();` && |\n| &&
|
||||||
|
` z2ui5.debugTool.show();` && |\n| &&
|
||||||
|
` } else {` && |\n| &&
|
||||||
|
` z2ui5.debugTool.close();` && |\n| &&
|
||||||
|
` z2ui5.debugTool = null;` && |\n| &&
|
||||||
|
` }` && |\n| &&
|
||||||
` }` && |\n| &&
|
` }` && |\n| &&
|
||||||
` });` && |\n| &&
|
` });` && |\n| &&
|
||||||
` },` && |\n| &&
|
` },` && |\n| &&
|
||||||
|
|
|
@ -157,6 +157,13 @@ CLASS z2ui5_cl_app_debugtool_js IMPLEMENTATION.
|
||||||
` this.oDialog.addStyleClass('dbg-ltr');` && |\n| &&
|
` this.oDialog.addStyleClass('dbg-ltr');` && |\n| &&
|
||||||
` this.oDialog.setModel(oModel);` && |\n| &&
|
` this.oDialog.setModel(oModel);` && |\n| &&
|
||||||
` this.oDialog.open();` && |\n| &&
|
` this.oDialog.open();` && |\n| &&
|
||||||
|
` },` && |\n| &&
|
||||||
|
`` && |\n| &&
|
||||||
|
` async close(){` && |\n| &&
|
||||||
|
` if (this.oDialog){` && |\n| &&
|
||||||
|
` this.oDialog.close();` && |\n| &&
|
||||||
|
` this.oDialog.destry();` && |\n| &&
|
||||||
|
` }` && |\n| &&
|
||||||
` }` && |\n| &&
|
` }` && |\n| &&
|
||||||
` });` && |\n| &&
|
` });` && |\n| &&
|
||||||
`});` && |\n| &&
|
`});` && |\n| &&
|
||||||
|
|
Loading…
Reference in New Issue
Block a user