mirror of
https://github.com/nasa/openmct.git
synced 2025-02-01 00:45:41 +00:00
[About] Add controllers
Add initial implementations of controllers to support showing the About dialog on logo click, WTD-667.
This commit is contained in:
parent
553eb2dd75
commit
150787b25f
@ -1,2 +1,4 @@
|
||||
<mct-include ng-click="" key="'app-logo'">
|
||||
</mct-include>
|
||||
<span ng-controller="LogoController as logo">
|
||||
<mct-include ng-click="show-about-dialog" key="'app-logo'">
|
||||
</mct-include>
|
||||
</span>
|
||||
|
21
platform/commonUI/about/src/AboutController.js
Normal file
21
platform/commonUI/about/src/AboutController.js
Normal file
@ -0,0 +1,21 @@
|
||||
/*global define*/
|
||||
|
||||
define(
|
||||
[],
|
||||
function () {
|
||||
"use strict";
|
||||
|
||||
function AboutController(versions, $window) {
|
||||
return {
|
||||
versions: function () {
|
||||
return versions;
|
||||
},
|
||||
openLicenses: function () {
|
||||
$window.open("#/licenses", "_blank");
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
return AboutController;
|
||||
}
|
||||
);
|
18
platform/commonUI/about/src/LogoController.js
Normal file
18
platform/commonUI/about/src/LogoController.js
Normal file
@ -0,0 +1,18 @@
|
||||
/*global define*/
|
||||
|
||||
define(
|
||||
[],
|
||||
function () {
|
||||
"use strict";
|
||||
|
||||
function LogoController(overlayService) {
|
||||
return {
|
||||
showAboutDialog: function () {
|
||||
overlayService.createOverlay("overlay-about");
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
return LogoController;
|
||||
}
|
||||
);
|
Loading…
x
Reference in New Issue
Block a user