[HippoCMS-scm] [Git][cms-community/hippo-cms][feature/CMS-10553] CMS-10553: refreshing tree model to refresh tree after folder renaming.

2017-05-23 Thread Woonsan Ko
Woonsan Ko pushed to branch feature/CMS-10553 at cms-community / hippo-cms


Commits:
ee79d4fc by Woonsan Ko at 2017-05-23T14:15:31-04:00
CMS-10553: refreshing tree model to refresh tree after folder renaming.

- - - - -


2 changed files:

- api/src/main/java/org/hippoecm/frontend/model/tree/JcrTreeNode.java
- 
perspectives/src/main/java/org/hippoecm/frontend/plugins/cms/browse/tree/FolderTreePlugin.java


Changes:

=
api/src/main/java/org/hippoecm/frontend/model/tree/JcrTreeNode.java
=
--- a/api/src/main/java/org/hippoecm/frontend/model/tree/JcrTreeNode.java
+++ b/api/src/main/java/org/hippoecm/frontend/model/tree/JcrTreeNode.java
@@ -43,7 +43,7 @@ public class JcrTreeNode extends 
NodeModelWrapper implements IJcrTr
 
 static final int DETACHING = 0x0001;
 
-private List children;
+private List children;
 
 private final int hashCode;
 private boolean reloadChildren = true;
@@ -139,6 +139,18 @@ public class JcrTreeNode extends 
NodeModelWrapper implements IJcrTr
 return true;
 }
 
+/**
+ * Ensure child tree nodes sorted properly.
+ */
+public void ensureChildrenSorted() {
+try {
+ensureChildrenLoaded();
+sortChildTreeNodes(children);
+} catch (RepositoryException e) {
+log.error("Failed to ensure children sorted.", e);
+}
+}
+
 // implement IDetachable
 
 @Override
@@ -242,7 +254,7 @@ public class JcrTreeNode extends 
NodeModelWrapper implements IJcrTr
 if (nodeModel.getObject() == null) {
 reloadChildren = false;
 reloadChildCount = false;
-children = new ArrayList();
+children = new ArrayList<>();
 childCount = 0;
 } else if (children == null || reloadChildren) {
 try {
@@ -250,7 +262,7 @@ public class JcrTreeNode extends 
NodeModelWrapper implements IJcrTr
 childCount = children.size();
 } catch (RepositoryException e) {
 log.warn("Unable to load children, setting empty list: " + 
e.getMessage());
-children = new ArrayList();
+children = new ArrayList<>();
 childCount = 0;
 }
 reloadChildren = false;


=
perspectives/src/main/java/org/hippoecm/frontend/plugins/cms/browse/tree/FolderTreePlugin.java
=
--- 
a/perspectives/src/main/java/org/hippoecm/frontend/plugins/cms/browse/tree/FolderTreePlugin.java
+++ 
b/perspectives/src/main/java/org/hippoecm/frontend/plugins/cms/browse/tree/FolderTreePlugin.java
@@ -231,6 +231,8 @@ public class FolderTreePlugin extends RenderPlugin {
 @Override
 public void onTargetRespond(final AjaxRequestTarget target, 
boolean dirty) {
 if (dirty) {
+rootNode.ensureChildrenSorted();
+tree.setDefaultModelObject(treeModel);
 
target.appendJavaScript(treeHelperBehavior.getRenderString());
 }
 }



View it on GitLab: 
https://code.onehippo.org/cms-community/hippo-cms/commit/ee79d4fcf43fc36d613847e6a03eac3de67c98df
___
Hippocms-svn mailing list
Hippocms-svn@lists.onehippo.org
https://lists.onehippo.org/mailman/listinfo/hippocms-svn


[HippoCMS-scm] [Git][cms-community/hippo-cms] Deleted branch feature/visual-editing-psp2-CMS-10715

2017-05-23 Thread Mathijs den Burger
Mathijs den Burger deleted branch feature/visual-editing-psp2-CMS-10715 at 
cms-community / hippo-cms
___
Hippocms-svn mailing list
Hippocms-svn@lists.onehippo.org
https://lists.onehippo.org/mailman/listinfo/hippocms-svn


[HippoCMS-scm] [Git][cms-community/hippo-addon-channel-manager] Deleted branch feature/visual-editing-psp2-CHANNELMGR-1268

2017-05-23 Thread Mathijs den Burger
Mathijs den Burger deleted branch feature/visual-editing-psp2-CHANNELMGR-1268 
at cms-community / hippo-addon-channel-manager
___
Hippocms-svn mailing list
Hippocms-svn@lists.onehippo.org
https://lists.onehippo.org/mailman/listinfo/hippocms-svn


[HippoCMS-scm] [Git][cms-community/hippo-addon-channel-manager] Deleted branch feature/visual-editing-psp2-CHANNELMGR-1249

2017-05-23 Thread Mathijs den Burger
Mathijs den Burger deleted branch feature/visual-editing-psp2-CHANNELMGR-1249 
at cms-community / hippo-addon-channel-manager
___
Hippocms-svn mailing list
Hippocms-svn@lists.onehippo.org
https://lists.onehippo.org/mailman/listinfo/hippocms-svn


[HippoCMS-scm] [Git][cms-community/hippo-addon-channel-manager] Deleted branch feature/visual-editing-psp2-CHANNELMGR-1236

2017-05-23 Thread Mathijs den Burger
Mathijs den Burger deleted branch feature/visual-editing-psp2-CHANNELMGR-1236 
at cms-community / hippo-addon-channel-manager
___
Hippocms-svn mailing list
Hippocms-svn@lists.onehippo.org
https://lists.onehippo.org/mailman/listinfo/hippocms-svn


[HippoCMS-scm] [Git][cms-community/hippo-addon-channel-manager] Deleted branch feature/visual-editing-psp2-CHANNELMGR-1234

2017-05-23 Thread Mathijs den Burger
Mathijs den Burger deleted branch feature/visual-editing-psp2-CHANNELMGR-1234 
at cms-community / hippo-addon-channel-manager
___
Hippocms-svn mailing list
Hippocms-svn@lists.onehippo.org
https://lists.onehippo.org/mailman/listinfo/hippocms-svn


[HippoCMS-scm] [Git][cms-community/hippo-addon-channel-manager] Deleted branch feature/visual-editing-psp2-CHANNELMGR-1199

2017-05-23 Thread Mathijs den Burger
Mathijs den Burger deleted branch feature/visual-editing-psp2-CHANNELMGR-1199 
at cms-community / hippo-addon-channel-manager
___
Hippocms-svn mailing list
Hippocms-svn@lists.onehippo.org
https://lists.onehippo.org/mailman/listinfo/hippocms-svn


[HippoCMS-scm] [Git][cms-community/hippo-addon-channel-manager] Deleted branch feature/visual-editing-psp2-CHANNELMGR-1043

2017-05-23 Thread Mathijs den Burger
Mathijs den Burger deleted branch feature/visual-editing-psp2-CHANNELMGR-1043 
at cms-community / hippo-addon-channel-manager
___
Hippocms-svn mailing list
Hippocms-svn@lists.onehippo.org
https://lists.onehippo.org/mailman/listinfo/hippocms-svn


[HippoCMS-scm] [Git][cms-community/hippo-cms][feature/CMS-10553] 2 commits: CMS-10553: Merge branch 'feature/CMS-10553' of https://code.onehippo.org/cms-com…

2017-05-23 Thread Woonsan Ko
Woonsan Ko pushed to branch feature/CMS-10553 at cms-community / hippo-cms


Commits:
e2a28d50 by Woonsan Ko at 2017-05-23T10:02:38-04:00
CMS-10553: Merge branch feature/CMS-10553 of 
https://code.onehippo.org/cms-community/hippo-cms into feature/CMS-10553

- - - - -
b64c9268 by Woonsan Ko at 2017-05-23T10:03:28-04:00
CMS-10553: Merge branch feature/CMS-10553 of 
https://code.onehippo.org/cms-community/hippo-cms into feature/CMS-10553

- - - - -


1 changed file:

- − 
api/src/main/java/org/hippoecm/frontend/plugins/standards/tree/JcrFolderTreeNameComparator.java


Changes:

=
api/src/main/java/org/hippoecm/frontend/plugins/standards/tree/JcrFolderTreeNameComparator.java
 deleted
=
--- 
a/api/src/main/java/org/hippoecm/frontend/plugins/standards/tree/JcrFolderTreeNameComparator.java
+++ /dev/null
@@ -1,39 +0,0 @@
-/*
- * Copyright 2017 Hippo B.V. (http://www.onehippo.com)
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.hippoecm.frontend.plugins.standards.tree;
-
-import java.util.Comparator;
-
-import javax.jcr.Node;
-
-import org.apache.wicket.util.io.IClusterable;
-import org.hippoecm.frontend.model.tree.IJcrTreeNode;
-import org.hippoecm.frontend.plugins.standards.list.comparators.NameComparator;
-
-public class JcrFolderTreeNameComparator implements Comparator, 
IClusterable {
-
-private Comparator nameComparator;
-
-public JcrFolderTreeNameComparator() {
-this.nameComparator = NameComparator.getInstance();
-}
-
-@Override
-public int compare(final IJcrTreeNode o1, final IJcrTreeNode o2) {
-return nameComparator.compare(o1.getNodeModel().getObject(), 
o2.getNodeModel().getObject());
-}
-}



View it on GitLab: 
https://code.onehippo.org/cms-community/hippo-cms/compare/30f6daec1f7edebaf3dfa5cf03cf36728e9e9cd9...b64c92680675080e385c55ca5db0abae0e0c62c0
___
Hippocms-svn mailing list
Hippocms-svn@lists.onehippo.org
https://lists.onehippo.org/mailman/listinfo/hippocms-svn


[HippoCMS-scm] [Git][cms-community/hippo-site-toolkit][feature/wpm] HSTTWO-4011 Correct typo isUserInRule into isUserInRole

2017-05-23 Thread Ard Schrijvers
Ard Schrijvers pushed to branch feature/wpm at cms-community / 
hippo-site-toolkit


Commits:
6fdcea89 by Ard Schrijvers at 2017-05-23T14:30:48+02:00
HSTTWO-4011 Correct typo isUserInRule into isUserInRole

- - - - -


4 changed files:

- api/src/main/java/org/hippoecm/hst/channelmanager/security/SecurityModel.java
- 
client-modules/page-composer/src/main/java/org/hippoecm/hst/pagecomposer/jaxrs/cxf/HstConfigSecurityAnnotationInvokerPreprocessor.java
- 
client-modules/page-composer/src/main/java/org/hippoecm/hst/pagecomposer/jaxrs/services/RootResource.java
- 
components/core/src/main/java/org/hippoecm/hst/channelmanager/security/SecurityModelImpl.java


Changes:

=
api/src/main/java/org/hippoecm/hst/channelmanager/security/SecurityModel.java
=
--- 
a/api/src/main/java/org/hippoecm/hst/channelmanager/security/SecurityModel.java
+++ 
b/api/src/main/java/org/hippoecm/hst/channelmanager/security/SecurityModel.java
@@ -40,5 +40,5 @@ public interface SecurityModel {
  * @return {@code true} when the user for the current {@code context} is 
in role {@code functionalRole} where the
  * {@code functionalRole} can be either {@link 
#CHANNEL_MANAGER_ADMIN_ROLE} or {@link #CHANNEL_WEBMASTER_ROLE}
  */
-boolean isUserInRule(Session session, String functionalRole);
+boolean isUserInRole(Session session, String functionalRole);
 }


=
client-modules/page-composer/src/main/java/org/hippoecm/hst/pagecomposer/jaxrs/cxf/HstConfigSecurityAnnotationInvokerPreprocessor.java
=
--- 
a/client-modules/page-composer/src/main/java/org/hippoecm/hst/pagecomposer/jaxrs/cxf/HstConfigSecurityAnnotationInvokerPreprocessor.java
+++ 
b/client-modules/page-composer/src/main/java/org/hippoecm/hst/pagecomposer/jaxrs/cxf/HstConfigSecurityAnnotationInvokerPreprocessor.java
@@ -49,7 +49,7 @@ public class HstConfigSecurityAnnotationInvokerPreprocessor 
extends SecurityAnno
 @Override
 public boolean isUserInRole(final String role) {
 try {
-return 
securityModel.isUserInRule(RequestContextProvider.get().getSession(), role);
+return 
securityModel.isUserInRole(RequestContextProvider.get().getSession(), role);
 } catch (RepositoryException e) {
 throw new IllegalStateException("Exception while trying to 
find whether user is " +
 "in role.", e);


=
client-modules/page-composer/src/main/java/org/hippoecm/hst/pagecomposer/jaxrs/services/RootResource.java
=
--- 
a/client-modules/page-composer/src/main/java/org/hippoecm/hst/pagecomposer/jaxrs/services/RootResource.java
+++ 
b/client-modules/page-composer/src/main/java/org/hippoecm/hst/pagecomposer/jaxrs/services/RootResource.java
@@ -221,8 +221,8 @@ public class RootResource extends AbstractConfigResource {
 
 final boolean isChannelDeletionSupported = 
isChannelDeletionSupported(mountId);
 try {
-final boolean hasAdminRole = 
securityModel.isUserInRule(requestContext.getSession(), 
CHANNEL_MANAGER_ADMIN_ROLE);
-final boolean isWebmaster = 
securityModel.isUserInRule(requestContext.getSession(), CHANNEL_WEBMASTER_ROLE);
+final boolean hasAdminRole = 
securityModel.isUserInRole(requestContext.getSession(), 
CHANNEL_MANAGER_ADMIN_ROLE);
+final boolean isWebmaster = 
securityModel.isUserInRole(requestContext.getSession(), CHANNEL_WEBMASTER_ROLE);
 final boolean canDeleteChannel = isChannelDeletionSupported && 
hasAdminRole;
 final boolean canManageChanges = hasAdminRole;
 


=
components/core/src/main/java/org/hippoecm/hst/channelmanager/security/SecurityModelImpl.java
=
--- 
a/components/core/src/main/java/org/hippoecm/hst/channelmanager/security/SecurityModelImpl.java
+++ 
b/components/core/src/main/java/org/hippoecm/hst/channelmanager/security/SecurityModelImpl.java
@@ -71,7 +71,7 @@ public class SecurityModelImpl implements SecurityModel {
  * whether a user was an admin or webmaster. Hence this kind of awkward 
looking implementation
  */
 @Override
-public boolean isUserInRule(final Session session, final String 
functionalRole) {
+public boolean isUserInRole(final Session session, final String 
functionalRole) {
 
 if (CHANNEL_MANAGER_ADMIN_ROLE.equals(functionalRole)) {
 final Map mapping = 
getMappingModel();



View it on GitLab: 
https://code.onehippo.org/cms-community/hippo-site-toolkit/commit/6fdcea895a67fa5af0d73727c75e4824fb6f900d
___
Hippocms-svn mailing list
Hippocms-svn@lists.onehippo.org
https://lists.onehippo.org/mailman/listinfo/hippocms-svn


[HippoCMS-scm] [Git][cms-community/hippo-addon-channel-manager][feature/visual-editing-psp2] CHANNELMGR-1278 resizeHandle coverage tests added to 100%

2017-05-23 Thread Ariel Weinberger
Ariel Weinberger pushed to branch feature/visual-editing-psp2 at cms-community 
/ hippo-addon-channel-manager


Commits:
03c58d59 by Ariel Weinberger at 2017-05-23T13:41:40+02:00
CHANNELMGR-1278 resizeHandle coverage tests added to 100%

- - - - -


2 changed files:

- 
frontend-ng/src/angularjs/channel/sidePanels/rightSidePanel/resizeHandle/resizeHandle.controller.js
- 
frontend-ng/src/angularjs/channel/sidePanels/rightSidePanel/resizeHandle/resizeHandle.controller.spec.js


Changes:

=
frontend-ng/src/angularjs/channel/sidePanels/rightSidePanel/resizeHandle/resizeHandle.controller.js
=
--- 
a/frontend-ng/src/angularjs/channel/sidePanels/rightSidePanel/resizeHandle/resizeHandle.controller.js
+++ 
b/frontend-ng/src/angularjs/channel/sidePanels/rightSidePanel/resizeHandle/resizeHandle.controller.js
@@ -20,7 +20,7 @@ class resizeHandleController {
 
 this.$document = $document;
 this.handle = $element;
-this.body = $('body');
+this.maxWidth = $('body').width() / 2;
   }
 
   $onInit() {
@@ -40,7 +40,7 @@ class resizeHandleController {
 const diff = initialX - moveEvent.pageX;
 newWidth = initialWidth + diff;
 
-if (newWidth > 440 && newWidth < (this.body.width() / 2)) {
+if (newWidth >= 440 && newWidth <= this.maxWidth) {
   manipulatedElement.css('width', newWidth);
   manipulatedElement.css('max-width', newWidth);
   this.onResize({ newWidth });


=
frontend-ng/src/angularjs/channel/sidePanels/rightSidePanel/resizeHandle/resizeHandle.controller.spec.js
=
--- 
a/frontend-ng/src/angularjs/channel/sidePanels/rightSidePanel/resizeHandle/resizeHandle.controller.spec.js
+++ 
b/frontend-ng/src/angularjs/channel/sidePanels/rightSidePanel/resizeHandle/resizeHandle.controller.spec.js
@@ -42,6 +42,7 @@ describe('resizeHandle component', () => {
   onResize: () => { },
 });
 
+$ctrl.maxWidth = 1350;
 spyOn($ctrl, 'onResize');
   });
 
@@ -94,7 +95,6 @@ describe('resizeHandle component', () => {
 $ctrl.$document.trigger(eMouseMove);
 
 $ctrl.$document.trigger('mouseup');
-expect($ctrl.onResize).toHaveBeenCalled();
 expect(mockSidePanelElement.css).not.toHaveBeenCalled();
   });
 });



View it on GitLab: 
https://code.onehippo.org/cms-community/hippo-addon-channel-manager/commit/03c58d59d9652b97674d348a502dd29d31bb520f
___
Hippocms-svn mailing list
Hippocms-svn@lists.onehippo.org
https://lists.onehippo.org/mailman/listinfo/hippocms-svn


[HippoCMS-scm] [Git][cms-community/hippo-cms-release][feature/visual-editing-psp2] 6 commits: CMS-10684 Add hippo patched jackrabbit version to the release pom

2017-05-23 Thread Mathijs den Burger
Mathijs den Burger pushed to branch feature/visual-editing-psp2 at 
cms-community / hippo-cms-release


Commits:
c2697dc5 by Ard Schrijvers at 2017-03-31T21:11:43+02:00
CMS-10684 Add hippo patched jackrabbit version to the release pom

>From now on, we manage the jackrabbit version via the release pom

- - - - -
52aa58c7 by Ard Schrijvers at 2017-04-11T09:17:18+02:00
CMS-10684 Add JR dependencies to dependency management

This way, end projects will transitively pull in the correct versions of JR as 
defined in
the release pom

- - - - -
1067782e by Ard Schrijvers at 2017-04-11T09:56:16+02:00
CMS-10684 Trim down the number of JR deps which are never used

- - - - -
7131a404 by Ard Schrijvers at 2017-04-11T10:44:44+02:00
CMS-10684 correct typo in version

- - - - -
2430c9f9 by Arent-Jan Banck at 2017-05-01T23:44:38+02:00
CMS-10716 Remove forge repository definition form the release pom and use same 
settings for the onehippo repository as the project pom

- - - - -
399885e5 by Mathijs den Burger at 2017-05-23T12:26:13+02:00
CMS-10635 Merge master changes into feature/visual-editing-psp2

- - - - -


2 changed files:

- − .gitattributes
- pom.xml


Changes:

=
.gitattributes deleted
=
--- a/.gitattributes
+++ /dev/null
@@ -1,4 +0,0 @@
-* text=auto !eol
-/LICENSE svneol=native#text/plain
-/NOTICE svneol=native#text/plain
-/pom.xml svneol=native#text/plain


=
pom.xml
=
--- a/pom.xml
+++ b/pom.xml
@@ -41,6 +41,8 @@
   
 12.0.0-SNAPSHOT
 
+2.14.0-h1-SNAPSHOT
+
 
4.0.0-SNAPSHOT
 
5.0.0-visual-editing-psp2-SNAPSHOT
 
4.0.0-SNAPSHOT
@@ -83,7 +85,7 @@
 
   
 
-  hippo
+  hippo-maven2
   Hippo Maven 2
   https://maven.onehippo.com/maven2/
   
@@ -91,26 +93,66 @@
   
   
 never
+fail
   
-  default
-
-
-  hippo-forge
-  Hippo Forge maven 2 repository.
-  https://maven.onehippo.com/maven2-forge/
-  
-false
-  
-  
-never
-  
-  default
 
-
   
 
   
 
+  
+  
+org.apache.jackrabbit
+jackrabbit-api
+${hippo.jackrabbit.version}
+  
+  
+org.apache.jackrabbit
+jackrabbit-aws-ext
+${hippo.jackrabbit.version}
+  
+  
+org.apache.jackrabbit
+jackrabbit-core
+${hippo.jackrabbit.version}
+  
+  
+org.apache.jackrabbit
+jackrabbit-data
+${hippo.jackrabbit.version}
+  
+  
+org.apache.jackrabbit
+jackrabbit-jcr-commons
+${hippo.jackrabbit.version}
+  
+  
+org.apache.jackrabbit
+jackrabbit-jcr-rmi
+${hippo.jackrabbit.version}
+  
+  
+org.apache.jackrabbit
+jackrabbit-jcr-servlets
+${hippo.jackrabbit.version}
+  
+  
+org.apache.jackrabbit
+jackrabbit-spi
+${hippo.jackrabbit.version}
+  
+  
+org.apache.jackrabbit
+jackrabbit-spi-commons
+${hippo.jackrabbit.version}
+  
+  
+org.apache.jackrabbit
+jackrabbit-vfs-ext
+${hippo.jackrabbit.version}
+  
+  
+
   
 org.onehippo.cms7
 hippo-cms7-commons



View it on GitLab: 
https://code.onehippo.org/cms-community/hippo-cms-release/compare/91c24c83390e25cad4e13de2367c342cc8bbdf23...399885e5fc91a23ac98d73b852e079bfc1e2c1d6
___
Hippocms-svn mailing list
Hippocms-svn@lists.onehippo.org
https://lists.onehippo.org/mailman/listinfo/hippocms-svn


[HippoCMS-scm] [Git][cms-community/hippo-site-toolkit][feature/wpm] HSTTWO-4022 Include node location in hash

2017-05-23 Thread Ard Schrijvers
Ard Schrijvers pushed to branch feature/wpm at cms-community / 
hippo-site-toolkit


Commits:
b99ed11c by Ard Schrijvers at 2017-05-23T12:15:40+02:00
HSTTWO-4022 Include node location in hash

- - - - -


2 changed files:

- 
components/core/src/main/java/org/hippoecm/hst/configuration/branch/WorkspaceHasher.java
- 
components/core/src/test/java/org/hippoecm/hst/configuration/branch/WorkspaceHasherIT.java


Changes:

=
components/core/src/main/java/org/hippoecm/hst/configuration/branch/WorkspaceHasher.java
=
--- 
a/components/core/src/main/java/org/hippoecm/hst/configuration/branch/WorkspaceHasher.java
+++ 
b/components/core/src/main/java/org/hippoecm/hst/configuration/branch/WorkspaceHasher.java
@@ -29,7 +29,6 @@ import javax.jcr.RepositoryException;
 import javax.jcr.Value;
 import javax.xml.bind.annotation.adapters.HexBinaryAdapter;
 
-import org.hippoecm.hst.configuration.HstNodeTypes;
 import org.hippoecm.hst.diagnosis.HDC;
 import org.hippoecm.hst.diagnosis.Task;
 import org.hippoecm.hst.statistics.Counter;
@@ -94,12 +93,13 @@ public class WorkspaceHasher implements NodeHasher {
 hashTask.setAttribute("Node path", node.getPath());
 }
 
-if (!isOrHasAncestorOfType(node, NODETYPE_HST_WORKSPACE)) {
+Node workspaceNode = getAncestorOrSelfOfType(node, 
NODETYPE_HST_WORKSPACE);
+if (workspaceNode == null) {
 throw new BranchException(String.format("Cannot not hash the 
node '%s' because not of type '%s' or " +
 "not a descendant of a node of type '%s'.", 
node.getPath(), NODETYPE_HST_WORKSPACE, NODETYPE_HST_WORKSPACE));
 }
 
-return startHashing(node, setHash, setUpstreamHash, counter);
+return startHashing(node, workspaceNode, setHash, setUpstreamHash, 
counter);
 
 } catch (RepositoryException | NoSuchAlgorithmException e) {
 try {
@@ -115,23 +115,29 @@ public class WorkspaceHasher implements NodeHasher {
 }
 }
 
-private boolean isOrHasAncestorOfType(final Node node, final String 
nodeType) throws RepositoryException {
+/**
+ * Returns ancestor node of type nodeType and {@code 
null} if no such ancestor present
+ */
+private Node getAncestorOrSelfOfType(final Node node, final String 
nodeType) throws RepositoryException {
 try {
-return node.isNodeType(nodeType) || 
isOrHasAncestorOfType(node.getParent(), nodeType);
+if (node.isNodeType(nodeType)) {
+return node;
+}
+return  getAncestorOrSelfOfType(node.getParent(), nodeType);
 } catch (ItemNotFoundException e) {
-return false;
+return null;
 }
 }
 
-private String startHashing(final Node node, final boolean setHash,
-  final boolean setUpstreamHash, final Counter 
counter) throws NoSuchAlgorithmException, RepositoryException {
+private String startHashing(final Node node, final Node workspaceNode, 
final boolean setHash,
+final boolean setUpstreamHash, final Counter 
counter) throws NoSuchAlgorithmException, RepositoryException {
 long start = System.currentTimeMillis();
-byte[] bytes = doHash(node, setHash, setUpstreamHash, counter);
+byte[] bytes = doHash(node, workspaceNode.getPath(), setHash, 
setUpstreamHash, counter);
 log.info("Hashing '{}' containing '{}' nodes took '{}' ms", 
node.getPath(), counter.getValue(), (System.currentTimeMillis() - start));
 return hexBinaryAdapter.marshal(bytes);
 }
 
-private byte[] doHash(final Node node, final boolean setHash,
+private byte[] doHash(final Node node, final String workspaceNodePath, 
final boolean setHash,
   final boolean setUpstreamHash, final Counter counter)
 throws RepositoryException, NoSuchAlgorithmException, 
BranchException {
 
@@ -142,7 +148,8 @@ public class WorkspaceHasher implements NodeHasher {
 }
 
 if (!node.isNodeType(NODETYPE_HST_WORKSPACE)) {
-md5.update(node.getName().getBytes());
+// include the relative path the node has below the workspace
+md5.update(node.getPath().substring(workspaceNodePath.length() + 
1).getBytes());
 }
 
 SortedSet sortedFilterPropertyNames = 
getSortedFilterPropertyNames(node);
@@ -163,7 +170,7 @@ public class WorkspaceHasher implements NodeHasher {
 confirmDeletedState(child);
 continue;
 }
-byte[] hash = doHash(child, setHash, setUpstreamHash, counter);
+byte[] hash = doHash(child, workspaceNodePath, setHash, 
setUpstreamHash, counter);
 md5.update(hash);
 }
 byte[] digest = md5.digest();


=

[HippoCMS-scm] [Git][cms-community/hippo-cms][feature/CMS-10553] CMS-10553 non-functional: add 'final' keyword to constant

2017-05-23 Thread Jeroen Hoffman
Jeroen Hoffman pushed to branch feature/CMS-10553 at cms-community / hippo-cms


Commits:
0161d046 by Jeroen Hoffman at 2017-05-23T11:50:34+02:00
CMS-10553 non-functional: add final keyword to constant

- - - - -


1 changed file:

- 
api/src/main/java/org/hippoecm/frontend/plugins/standards/tree/FolderTreeNode.java


Changes:

=
api/src/main/java/org/hippoecm/frontend/plugins/standards/tree/FolderTreeNode.java
=
--- 
a/api/src/main/java/org/hippoecm/frontend/plugins/standards/tree/FolderTreeNode.java
+++ 
b/api/src/main/java/org/hippoecm/frontend/plugins/standards/tree/FolderTreeNode.java
@@ -42,7 +42,7 @@ public class FolderTreeNode extends JcrTreeNode {
 /**
  * Comparator by folder display name.
  */
-private static Comparator DISPLAY_NAME_COMPARATOR = new 
JcrTreeNameComparator();
+private static final Comparator DISPLAY_NAME_COMPARATOR = 
new JcrTreeNameComparator();
 
 /**
  * Returns {@link #DISPLAY_NAME_COMPARATOR} if the current folder node is 
of {@link HippoStdNodeType#NT_DIRECTORY}



View it on GitLab: 
https://code.onehippo.org/cms-community/hippo-cms/commit/0161d04628bb17723f557b8e5be2165762bb193f
___
Hippocms-svn mailing list
Hippocms-svn@lists.onehippo.org
https://lists.onehippo.org/mailman/listinfo/hippocms-svn


[HippoCMS-scm] [Git][cms-community/hippo-cms][feature/CMS-10553] CMS-10553 non-functional: remove serialVersionUID

2017-05-23 Thread Jeroen Hoffman
Jeroen Hoffman pushed to branch feature/CMS-10553 at cms-community / hippo-cms


Commits:
ef04bdbe by Jeroen Hoffman at 2017-05-23T11:40:25+02:00
CMS-10553 non-functional: remove serialVersionUID

- - - - -


1 changed file:

- api/src/main/java/org/hippoecm/frontend/model/tree/JcrTreeNode.java


Changes:

=
api/src/main/java/org/hippoecm/frontend/model/tree/JcrTreeNode.java
=
--- a/api/src/main/java/org/hippoecm/frontend/model/tree/JcrTreeNode.java
+++ b/api/src/main/java/org/hippoecm/frontend/model/tree/JcrTreeNode.java
@@ -38,7 +38,6 @@ import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
 public class JcrTreeNode extends NodeModelWrapper implements 
IJcrTreeNode {
-private static final long serialVersionUID = 1L;
 
 static final Logger log = LoggerFactory.getLogger(JcrTreeNode.class);
 



View it on GitLab: 
https://code.onehippo.org/cms-community/hippo-cms/commit/ef04bdbe81740e8b2c66dca5ef38f92b060e2da1
___
Hippocms-svn mailing list
Hippocms-svn@lists.onehippo.org
https://lists.onehippo.org/mailman/listinfo/hippocms-svn


[HippoCMS-scm] [Git][cms-community/hippo-cms][feature/CMS-10553] 32 commits: CMS-10143 make the area with new field options a bit less high

2017-05-23 Thread Jeroen Hoffman
Jeroen Hoffman pushed to branch feature/CMS-10553 at cms-community / hippo-cms


Commits:
726a30f8 by Bert Leunis at 2017-05-15T10:57:39+02:00
CMS-10143 make the area with new field options a bit less high

- - - - -
070b232f by Bert Leunis at 2017-05-15T13:04:14+02:00
CMS-10411 reorder system info; removed GC button

- - - - -
2db0e6aa by Bert Leunis at 2017-05-15T15:46:54+02:00
CMS-10420 use label instead of span

- - - - -
bad7d669 by Bert Leunis at 2017-05-15T16:02:06+02:00
CMS-10420 three more occurences of a checkbox with a clickable label

- - - - -
5142f3e3 by Bert Leunis at 2017-05-16T10:17:15+02:00
CMS-10646 do not use namespace in field name nor caption

- - - - -
7ab0e7f0 by Bert Leunis at 2017-05-18T11:29:16+02:00
Merge branch master into feature/CMS-10646

- - - - -
92fb082e by Bert Leunis at 2017-05-18T11:31:45+02:00
CMS-10646 strip path property for non-primitives

- - - - -
098fb02f by Arthur Bogaart at 2017-05-18T22:58:33+02:00
CMS-10656 Code cleanup

- - - - -
a9593ddb by Jeroen Hoffman at 2017-05-19T11:50:16+02:00
CMS-10420 Merge branch master into feature/CMS-10420

- - - - -
623749cb by Jeroen Hoffman at 2017-05-19T11:51:43+02:00
CMS-10420 Reintegrate branch feature/CMS-10420

- - - - -
12a17802 by Jeroen Hoffman at 2017-05-19T12:14:48+02:00
CMS-10143 Merge branch master into feature/CMS-10143

- - - - -
dc5a1188 by Jeroen Hoffman at 2017-05-19T12:17:29+02:00
CMS-10143 Reintegrate branch feature/CMS-10143

- - - - -
b5aebac9 by Jeroen Hoffman at 2017-05-19T13:36:06+02:00
CMS-10411 add View before the system info hint, to be more in line 
with the other hints

- - - - -
afe3da4f by Jeroen Hoffman at 2017-05-19T14:00:49+02:00
CMS-10411 remove serialVersionUID

- - - - -
3bda18d3 by Jeroen Hoffman at 2017-05-19T14:05:55+02:00
CMS-10411 uncapitalize Version twice, to be in line with the other 
4 occurences

- - - - -
fd106b39 by Jeroen Hoffman at 2017-05-19T14:24:56+02:00
CMS-10411 Merge branch master into feature/CMS-10411

- - - - -
53db1397 by Jeroen Hoffman at 2017-05-19T14:26:38+02:00
CMS-10411 Reintegrate branch feature/CMS-10411

- - - - -
b9d5c66f by Joeri de Gooijer at 2017-05-19T14:36:39+02:00
CMS-10750 Add all files for blueimp fileupload

- - - - -
a7ebbea4 by Arthur Bogaart at 2017-05-19T15:21:43+02:00
CMS-10656 Replace BrowsableModel with preview-links-service

Instead of editing the HTML of the previewdiff view on the server
(regular expressions..) to insert click handlers for internal links,
use a client-side script that registers onlick handlers (using jQuery)
and triggers a callback using the data-uuid attribute value.

- - - - -
a53268fa by Arthur Bogaart at 2017-05-19T15:23:18+02:00
CMS-10656 Update the styling of diff-changed blocks

Changed blocks get a light blue background color and no more
underline gif

- - - - -
6db5af7d by Jeroen Hoffman at 2017-05-19T15:45:01+02:00
CMS-10646 Merge branch master into feature/CMS-10646

- - - - -
dad0d334 by Jeroen Hoffman at 2017-05-22T09:28:05+02:00
CMS-10646 use StringUtils.substringAfter the both occasions with the same logic

- - - - -
6b1c9be7 by Jeroen Hoffman at 2017-05-22T09:29:55+02:00
CMS-10646 remove serialVersionUIDs, no longer needed

- - - - -
8252b41c by Jeroen Hoffman at 2017-05-22T09:38:07+02:00
CMS-10646 Reintegrate branch feature/CMS-10646

- - - - -
ddae21f5 by Mathijs den Burger at 2017-05-22T10:44:32+02:00
CMS-10656 Add jslint plugin to richtext/frontend module

- - - - -
fe8683b1 by Mathijs den Burger at 2017-05-22T10:46:39+02:00
CMS-10656 Also log exception when node cannot be found, code cleanup

- - - - -
33300d22 by Mathijs den Burger at 2017-05-22T11:01:37+02:00
CMS-10656 Remove unused diff images and CSS classes

None of the removed images and CSS classes are used anywhere in
the CMS.

- - - - -
fd32471f by Mathijs den Burger at 2017-05-22T12:19:38+02:00
CMS-10656 Move diff CSS to SCSS

The AbstractRichTextDiffPanel only included the diff.css, so it
can be removed. Its sub-classes can now directly extend its
super class AbstractRichTextViewPanel.

- - - - -
acef9ea6 by Mathijs den Burger at 2017-05-22T12:44:11+02:00
CMS-10656 Use the same diff colors everywhere

Also moved the existing rules for compare/diff to _editor_diff.

The rules for .hippo-dif-added and .hippo-dif-removed were
dead code because of the typo (dif vs diff) and have been
removed.

- - - - -
03ec4cee by Mathijs den Burger at 2017-05-22T12:47:52+02:00
CMS-10656 Reintegrate bugfix/CMS-10656

- - - - -
53e6c331 by Jeroen Hoffman at 2017-05-23T10:03:24+02:00
CMS-10553 Merge branch master into feature/CMS-10553

- - - - -
f5c44096 by Jeroen Hoffman at 2017-05-23T10:13:01+02:00
CMS-10553 non-functional: remove serialVersionUIDs, update copyright years

- - - - -


30 changed files:

- api/Gruntfile.js
- api/src/main/java/org/hippoecm/frontend/model/SystemInfoDataProvider.java
- api/src/main/java/org/hippoecm/frontend/model/tree/JcrTreeNameComparator.java
- api/src/main/java/org/hippoecm/frontend/model/tree/JcrTreeNode.java
- 

[HippoCMS-scm] [Git][cms-community/hippo-site-toolkit][feature/wpm] HSTTWO-4005 remove mandatory from hst:hash

2017-05-23 Thread Ard Schrijvers
Ard Schrijvers pushed to branch feature/wpm at cms-community / 
hippo-site-toolkit


Commits:
b57b9c28 by Ard Schrijvers at 2017-05-23T10:21:06+02:00
HSTTWO-4005 remove mandatory from hst:hash

It shouldnt be mandatory

- - - - -


1 changed file:

- toolkit-resources/addon/toolkit-cnd/cnd/src/main/resources/hst-types.cnd


Changes:

=
toolkit-resources/addon/toolkit-cnd/cnd/src/main/resources/hst-types.cnd
=
--- a/toolkit-resources/addon/toolkit-cnd/cnd/src/main/resources/hst-types.cnd
+++ b/toolkit-resources/addon/toolkit-cnd/cnd/src/main/resources/hst-types.cnd
@@ -261,7 +261,7 @@
 + hst:upstream (hst:workspace) = hst:workspace
 
 [hst:hashable] mixin
-- hst:hash (string) mandatory
+- hst:hash (string)
 - hst:upstreamhash (string)
 - hst:deleted (boolean)
 



View it on GitLab: 
https://code.onehippo.org/cms-community/hippo-site-toolkit/commit/b57b9c2825a1be3f77969c6e0951f4091c8cd07a
___
Hippocms-svn mailing list
Hippocms-svn@lists.onehippo.org
https://lists.onehippo.org/mailman/listinfo/hippocms-svn


[HippoCMS-scm] [Git][cms-community/hippo-cms] Deleted branch bugfix/CMS-10555

2017-05-23 Thread Jeroen Hoffman
Jeroen Hoffman deleted branch bugfix/CMS-10555 at cms-community / hippo-cms
___
Hippocms-svn mailing list
Hippocms-svn@lists.onehippo.org
https://lists.onehippo.org/mailman/listinfo/hippocms-svn


[HippoCMS-scm] [Git][cms-community/hippo-cms] Deleted branch feature/CMS-10721

2017-05-23 Thread Jeroen Hoffman
Jeroen Hoffman deleted branch feature/CMS-10721 at cms-community / hippo-cms
___
Hippocms-svn mailing list
Hippocms-svn@lists.onehippo.org
https://lists.onehippo.org/mailman/listinfo/hippocms-svn