NIFI-1782 cleanup whitespace and code styles

This closes #411
This commit is contained in:
Scott Aslan 2016-05-03 15:01:10 -04:00 committed by Oleg Zhurakousky
parent 194fc048fb
commit 2824f5a23c
13 changed files with 56 additions and 44 deletions

View File

@ -646,4 +646,3 @@ This product bundles 'Fontello' which is available under an MIT license.
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.

View File

@ -9,4 +9,3 @@ SIL OFL 1.1
The following binary components are provided under the SIL Open Font License 1.1
(SIL OFL 1.1) FontAwesome (4.6.1 - http://fortawesome.github.io/Font-Awesome/license/)

View File

@ -66,17 +66,17 @@ nf.ng.BreadcrumbsCtrl = (function () {
/**
* Update the breadcrumbs css.
*
*
* @param {object} style The style to be applied.
*/
updateBreadcrumbsCss: function(style){
updateBreadcrumbsCss: function (style) {
$('#breadcrumbs').css(style);
},
/**
* Reset initial scroll position.
*/
resetScrollPosition: function(){
resetScrollPosition: function () {
var title = $('#data-flow-title-container');
var titlePosition = title.position();
var titleWidth = title.outerWidth();
@ -98,10 +98,10 @@ nf.ng.BreadcrumbsCtrl = (function () {
/**
* Registers a scroll event on the `element`
*
*
* @param {object} element The element event listener will be registered upon.
*/
registerMouseWheelEvent: function(element){
registerMouseWheelEvent: function (element) {
// mousewheel -> IE, Chrome
// DOMMouseScroll -> FF
// wheel -> FF, IE

View File

@ -37,7 +37,7 @@ nf.ng.Canvas.AppCtrl = (function () {
nf.ng.Bridge.setRootScope($scope);
}
AppCtrl.$inject=['$scope', 'serviceProvider', 'headerCtrl', 'graphControlsCtrl'];
AppCtrl.$inject = ['$scope', 'serviceProvider', 'headerCtrl', 'graphControlsCtrl'];
return AppCtrl;
}());

View File

@ -157,7 +157,7 @@ nf.ng.Canvas.GraphControlsCtrl = (function () {
* Undock the graph control.
* @param {jQuery} $event
*/
undock: function($event){
undock: function ($event) {
openGraphControl($($event.target).parent().parent());
},
@ -165,7 +165,7 @@ nf.ng.Canvas.GraphControlsCtrl = (function () {
* Expand the graph control.
* @param {jQuery} $event
*/
expand: function($event){
expand: function ($event) {
var icon = $($event.target);
if (icon.hasClass('fa-plus-square-o')) {
openGraphControl(icon.closest('div.graph-control'));

View File

@ -26,8 +26,11 @@ nf.ng.Canvas.NavigateCtrl = (function () {
};
NavigateCtrl.prototype = {
constructor: NavigateCtrl,
zoomIn: function(){
/**
* Zoom in on the canvas.
*/
zoomIn: function () {
nf.Canvas.View.zoomIn();
// hide the context menu
@ -38,8 +41,11 @@ nf.ng.Canvas.NavigateCtrl = (function () {
transition: true
});
},
zoomOut: function(){
/**
* Zoom out on the canvas.
*/
zoomOut: function () {
nf.Canvas.View.zoomOut();
// hide the context menu
@ -50,8 +56,11 @@ nf.ng.Canvas.NavigateCtrl = (function () {
transition: true
});
},
zoomFit: function(){
/**
* Zoom fit on the canvas.
*/
zoomFit: function () {
nf.Canvas.View.fit();
// hide the context menu
@ -62,8 +71,11 @@ nf.ng.Canvas.NavigateCtrl = (function () {
transition: true
});
},
zoomActualSize: function(){
/**
* Zoom actual size on the canvas.
*/
zoomActualSize: function () {
nf.Canvas.View.actualSize();
// hide the context menu

View File

@ -74,7 +74,7 @@ nf.ng.OutputPortComponent = (function () {
* The output port component's modal.
*/
modal: {
/**
* Gets the modal element.
*

View File

@ -249,12 +249,12 @@ nf.ng.ProcessorComponent = (function () {
* The processor component's modal.
*/
modal: {
/**
* The processor component modal's filter.
*/
filter: {
/**
* Initialize the filter.
*/

View File

@ -74,7 +74,7 @@ nf.ng.RemoteProcessGroupComponent = (function () {
* The remote group component's modal.
*/
modal: {
/**
* Gets the modal element.
*

View File

@ -66,7 +66,7 @@ nf.ng.TemplateComponent = (function () {
* The template component's modal.
*/
modal: {
/**
* Gets the modal element.
*

View File

@ -27,14 +27,14 @@ nf.ng.Canvas.AppConfig = (function () {
$mdThemingProvider.definePalette('basePalette', {
'50': '728E9B',
'100': '728E9B',
'200': '004849',/* link-color */
'300': '775351',/* value-color */
'200': '004849', /* link-color */
'300': '775351', /* value-color */
'400': '728E9B',
'500': '728E9B',/* base-color */
'500': '728E9B', /* base-color */
'600': '728E9B',
'700': '728E9B',
'800': '728E9B',
'900': 'rgba(249,250,251,0.97)',/* tint base-color 96% */
'900': 'rgba(249,250,251,0.97)', /* tint base-color 96% */
'A100': '728E9B',
'A200': '728E9B',
'A400': '728E9B',
@ -46,13 +46,13 @@ nf.ng.Canvas.AppConfig = (function () {
$mdThemingProvider.definePalette('tintPalette', {
'50': '728E9B',
'100': '728E9B',
'200': 'CCDADB',/* tint link-color 20% */
'200': 'CCDADB', /* tint link-color 20% */
'300': '728E9B',
'400': 'AABBC3',/* tint base-color 40% */
'400': 'AABBC3', /* tint base-color 40% */
'500': '728E9B',
'600': 'C7D2D7',/* tint base-color 60% */
'600': 'C7D2D7', /* tint base-color 60% */
'700': '728E9B',
'800': 'E3E8EB',/* tint base-color 80% */
'800': 'E3E8EB', /* tint base-color 80% */
'900': '728E9B',
'A100': '728E9B',
'A200': '728E9B',
@ -68,7 +68,7 @@ nf.ng.Canvas.AppConfig = (function () {
'200': 'BA554A',
'300': 'BA554A',
'400': 'BA554A',
'500': 'BA554A',/* warn-color */
'500': 'BA554A', /* warn-color */
'600': 'BA554A',
'700': 'BA554A',
'800': 'BA554A',
@ -96,7 +96,7 @@ nf.ng.Canvas.AppConfig = (function () {
});
}
AppConfig.$inject=['$mdThemingProvider', '$compileProvider'];
AppConfig.$inject = ['$mdThemingProvider', '$compileProvider'];
return AppConfig;
}());

View File

@ -24,16 +24,16 @@ nf.ng.Bridge = (function () {
};
AngularBridge.prototype = {
constructor: AngularBridge,
/**
* Sets the root scope for the angular application being bridged.
*
* @param {object} scope An object that refers to the application model.
*/
setRootScope: function(scope){
setRootScope: function (scope) {
this.rootScope = scope;
},
/**
* Inspects the root scope of the bridged angular application to look up
* objects (to be provided as the `this` context) and invoke methods.
@ -63,19 +63,19 @@ nf.ng.Bridge = (function () {
var args = Array.prototype.slice.call(arguments, 2);
var result = fun.apply(obj, args);
this.rootScope.$apply();
if(result){
if (result) {
return result;
}
},
/**
* Inspects the root scope of the bridged angular application to look up
* and return object.
*
* and return object.
*
* @param {string} name The name of the object to lookup.
* @returns {Object|*}
*/
get: function(name){
get: function (name) {
var objArray = name.split(".");
var obj = this.rootScope;
angular.forEach(objArray, function (value) {
@ -84,7 +84,7 @@ nf.ng.Bridge = (function () {
return obj;
},
digest: function(){
digest: function () {
this.rootScope.$digest();
}
};

View File

@ -24,21 +24,23 @@ nf.ng.ServiceProvider = (function () {
};
ServiceProvider.prototype = {
constructor: ServiceProvider,
/**
* Registers the given `object` by `name`.
*
* @param {string} name The lookup name of the object being registered
* @param {object} object The object to register
*/
register: function(name, object) {
register: function (name, object) {
serviceProvider[name] = object;
},
/**
* Removes the given object from the registry.
*
* @param {string objectName The lookup name of the object to remove from the registry
*/
remove: function(objectName) {
remove: function (objectName) {
delete serviceProvider[objectName];
}
};
@ -46,7 +48,7 @@ nf.ng.ServiceProvider = (function () {
return serviceProvider;
}
ServiceProvider.$inject=[];
ServiceProvider.$inject = [];
return ServiceProvider;
}());