Skip to content

Commit

Permalink
Merge branch 'hotfix/220-fixing-metadata-bugs' into develop
Browse files Browse the repository at this point in the history
  • Loading branch information
forkch committed Jul 29, 2014
2 parents 5d60bc3 + 220901f commit 24f799a
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@

'use strict';

angular.module('scenarioo.directives').directive('scShowHideDetailsButton', function($window, localStorageService) {
angular.module('scenarioo.directives').directive('scShowHideDetailsButton', function($window, localStorageService, GlobalHotkeysService) {

var STEP_METADATA_VISIBLE = 'scenarioo-metadataVisible-';
function initMetadataVisibleFromLocalStorage(scope, key) {
Expand All @@ -40,6 +40,11 @@ angular.module('scenarioo.directives').directive('scShowHideDetailsButton', func
localStorageKey: '@'
},
templateUrl: 'views/showHideDetailsButton.html',
link: function(scope) {
GlobalHotkeysService.registerGlobalHotkey('d', function () {
scope.toggleShowingMetadata();
});
},
controller: function($scope) {
initMetadataVisibleFromLocalStorage($scope, $scope.localStorageKey);
$scope.toggleShowingMetadata = function() {
Expand Down
6 changes: 4 additions & 2 deletions scenarioo-client/app/views/applicationInfoPopup.html
Original file line number Diff line number Diff line change
Expand Up @@ -85,8 +85,10 @@ <h3>Shortcuts for navigating by keys in Scenarioo</h3>

</dl>
<dl class="dl-horizontal">
<dt>h</dt>
<dd>Home</dd>
<dt>h</dt>
<dd>Home</dd>
<dt>d</dt>
<dd>Toggle show meta data</dd>
<dt>c</dt>
<dd>Configure Scenarioo</dd>
<dt>m</dt>
Expand Down
2 changes: 1 addition & 1 deletion scenarioo-client/app/views/scenario.html
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ <h2 class="sc-pageTitle">{{scenario.description}}</h2>
<!-- steps -->
<div class="row step-view">
<div ng-repeat="page in pagesAndSteps">
<div ng-repeat="step in page.steps | scFilterArray:searchFieldText" ng-show="$index == 0 || showAllStepsForPage($parent.$index)" class="sc-step-in-overview" ng-class="{'col-md-4': !showingMetaData, 'col-md-6': showingMetaData}">
<div ng-repeat="step in page.steps | scFilterArray:searchFieldText" ng-show="$index == 0 || showAllStepsForPage($parent.$index)" class="sc-step-in-overview" ng-class="{'col-md-4': !scenarioShowMetadata, 'col-md-6': scenarioShowMetadata}">
<h2>
<span class="sc-truncate" ng-if="$index == 0">
<span class="sc-no-truncate">
Expand Down
2 changes: 1 addition & 1 deletion scenarioo-client/app/views/usecase.html
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ <h2 class="sc-pageTitle">{{useCase.description}}</h2>
</div>
</div>
<div class="col-lg-9">
<sc-show-hide-details-button linking-variable="useCaseShowMetadata" local-storage-key="main" ></sc-show-hide-details-button>
<sc-show-hide-details-button linking-variable="useCaseShowMetadata" local-storage-key="usecase" ></sc-show-hide-details-button>
</div>
</div>

Expand Down

0 comments on commit 24f799a

Please sign in to comment.