[Fixed Position] Begin breaking apart template

Begin breaking apart template to allow multiple
types of fixed position elements, WTD-879.
This commit is contained in:
Victor Woeltjen 2015-02-18 13:19:59 -08:00
parent 97b844563d
commit 8662689974
2 changed files with 21 additions and 22 deletions

View File

@ -0,0 +1,8 @@
<div style="background: #444;">
<div style="position: absolute; left: 0px; top: 0px; bottom: 0px; width: 50%; overflow: hidden;">
{{ngModel.name}}
</div>
<div style="position: absolute; right: 0px; top: 0px; bottom: 0px; width: 50%; overflow: hidden;">
{{ngModel.value}}
</div>
</div>

View File

@ -1,5 +1,3 @@
<div style="width: 100%; height: 100%; position: absolute; left: 0px; top: 0px;"
ng-controller="FixedController as controller"
mct-resize="controller.setBounds(bounds)">
@ -11,26 +9,19 @@
</div>
<!-- Telemetry elements -->
<div ng-repeat="childObject in composition"
style="position: absolute; background: #444;"
ng-style="controller.getStyle(childObject.getId())">
<mct-include ng-repeat="element in controller.getDecoratedElements()"
style="position: absolute;"
ng-style="element.style"
key="element.template"
ng-model="element">
</mct-include>
<div style="position: absolute; left: 0px; top: 0px; bottom: 0px; width: 50%; overflow: hidden;">
{{childObject.getModel().name}}
</div>
<div style="position: absolute; right: 0px; top: 0px; bottom: 0px; width: 50%; overflow: hidden;">
{{controller.getValue(childObject.getId())}}
</div>
<!-- Drag handles -->
<span ng-show="domainObject.hasCapability('editor')">
<span style="position: absolute; left: 0px; right: 0px; top: 0px; bottom: 0px; cursor: move;"
mct-drag-down="controller.startDrag(childObject.getId(), [1,1], [0,0])"
mct-drag="controller.continueDrag(delta)"
mct-drag-up="controller.endDrag()">
</span>
<!-- Drag handles -->
<span ng-show="false && domainObject.hasCapability('editor')">
<span style="position: absolute; left: 0px; right: 0px; top: 0px; bottom: 0px; cursor: move;"
mct-drag-down="controller.startDrag(element, [1,1], [0,0])"
mct-drag="controller.continueDrag(element)"
mct-drag-up="controller.endDrag()">
</span>
</div>
</span>
</div>