Merge remote-tracking branch 'origin/dev-v7' into dev-v8

This commit is contained in:
Shannon
2016-03-17 14:30:02 +01:00
5 changed files with 18 additions and 6 deletions

View File

@@ -1,4 +1,4 @@
<div class="umb-panel umb-editor-wrapper animated -half-second fadeIn"
<div class="umb-panel umb-editor-wrapper"
ng-class="{
'-no-footer': footer === 'false'
}"

View File

@@ -166,17 +166,17 @@
<div class="row form-search">
<div class="span8 input-append">
<input type="text" class="search-query" ng-model="searcher.searchText" />
<input type="text" class="search-query" ng-model="searcher.searchText" no-dirty-check />
<button type="submit" class="btn btn-info" ng-click="search(searcher)" ng-disabled="searcher.isProcessing">Search</button>
</div>
</div>
<div class="row">
<label for="{{searcher.name}}-textSearch" class="radio inline">
<input type="radio" name="searchType" id="{{searcher.name}}-textSearch" value="text" ng-model="searcher.searchType" />
<input type="radio" name="searchType" id="{{searcher.name}}-textSearch" value="text" ng-model="searcher.searchType" no-dirty-check />
Text Search
</label>
<label for="{{searcher.name}}-luceneSearch" class="radio inline">
<input type="radio" name="searchType" id="{{searcher.name}}-luceneSearch" value="lucene" ng-model="searcher.searchType" />
<input type="radio" name="searchType" id="{{searcher.name}}-luceneSearch" value="lucene" ng-model="searcher.searchType" no-dirty-check />
Lucene Search
</label>
</div>

View File

@@ -16,7 +16,7 @@
vm.nodeId = $scope.contentId;
//vm.acceptedFileTypes = mediaHelper.formatFileTypes(Umbraco.Sys.ServerVariables.umbracoSettings.imageFileTypes);
//instead of passing in a whitelist, we pass in a blacklist by adding ! to the ext
vm.acceptedFileTypes = mediaHelper.formatFileTypes(Umbraco.Sys.ServerVariables.umbracoSettings.disallowedUploadFiles).replace(/./g, "!.");
vm.acceptedFileTypes = mediaHelper.formatFileTypes(Umbraco.Sys.ServerVariables.umbracoSettings.disallowedUploadFiles).replace(/\./g, "!.");
vm.maxFileSize = Umbraco.Sys.ServerVariables.umbracoSettings.maxFileSize + "KB";
vm.activeDrag = false;

View File

@@ -35,9 +35,18 @@ Umbraco.Sys.registerNamespace("Umbraco.Controls.CodeEditor");
this._control.val(code);
}
else {
//this is a wrapper for CodeMirror
//this is a wrapper for CodeMirror
this._editor.focus();
var codeChanged = this._editor.getValue() != code;
var cursor = this._editor.doc.getCursor();
this._editor.setValue(code);
// Restore cursor position if the server saved code matches.
if (!codeChanged)
this._editor.setCursor(cursor);
this._editor.focus();
}
},

View File

@@ -174,6 +174,9 @@
}
if (args.contents) {
UmbEditor.SetCode(args.contents);
} else if (!this.IsSimpleEditor) {
// Restore focuse to text region. SetCode also does this.
UmbEditor._editor.focus();
}
UmbClientMgr.mainTree().setActiveTreeType(this._opts.currentTreeType);