Index: lams_central/web/author2.jsp
===================================================================
diff -u -r77fdf7d8fee9946573a774963d4904acf62976d9 -rf9c27273356e1547373560d374e9b306295df2cb
--- lams_central/web/author2.jsp (.../author2.jsp) (revision 77fdf7d8fee9946573a774963d4904acf62976d9)
+++ lams_central/web/author2.jsp (.../author2.jsp) (revision f9c27273356e1547373560d374e9b306295df2cb)
@@ -16,6 +16,7 @@
+
Index: lams_central/web/css/authoring.css
===================================================================
diff -u -r77fdf7d8fee9946573a774963d4904acf62976d9 -rf9c27273356e1547373560d374e9b306295df2cb
--- lams_central/web/css/authoring.css (.../authoring.css) (revision 77fdf7d8fee9946573a774963d4904acf62976d9)
+++ lams_central/web/css/authoring.css (.../authoring.css) (revision f9c27273356e1547373560d374e9b306295df2cb)
@@ -43,7 +43,7 @@
input.groupName {
margin-bottom: 5px;
- width: 100%;
+ width: 98%;
}
@@ -54,7 +54,7 @@
div#ldStoreDialog > table {
width: 100%;
- height: 684px;
+ height: 682px;
table-layout: fixed;
border-top: thin dotted #2E6E9E;
}
@@ -145,7 +145,7 @@
}
div#templateContainer {
- height: 745px;
+ height: 741px;
overflow: auto;
}
@@ -168,7 +168,7 @@
#canvas {
overflow: auto;
- width: 100%;
- height: 745px;
+ width: 844px;
+ height: 741px;
vertical-align: top;
}
\ No newline at end of file
Index: lams_central/web/includes/javascript/authoring/authoringActivity.js
===================================================================
diff -u -r77fdf7d8fee9946573a774963d4904acf62976d9 -rf9c27273356e1547373560d374e9b306295df2cb
--- lams_central/web/includes/javascript/authoring/authoringActivity.js (.../authoringActivity.js) (revision 77fdf7d8fee9946573a774963d4904acf62976d9)
+++ lams_central/web/includes/javascript/authoring/authoringActivity.js (.../authoringActivity.js) (revision f9c27273356e1547373560d374e9b306295df2cb)
@@ -261,14 +261,17 @@
$('input, select', content).change(function(){
// extract changed properties and redraw the activity
var redrawNeeded = false,
- newTitle = $('.propertiesContentFieldTitle', activity.propertiesContent).val();
+ newTitle = $('.propertiesContentFieldTitle', activity.propertiesContent).val();
if (newTitle != activity.title) {
activity.title = newTitle;
redrawNeeded = true;
}
-
- activity.grouping = $('.propertiesContentFieldGrouping option:selected', activity.propertiesContent)
+ var newGroupingValue = $('.propertiesContentFieldGrouping option:selected', activity.propertiesContent)
.data('grouping');
+ if (newGroupingValue != activity.grouping) {
+ activity.grouping = newGroupingValue;
+ redrawNeeded = true;
+ }
activity.defineInMonitor = $('.propertiesContentFieldDefineMonitor', activity.propertiesContent)
.is(':checked');
var newOfflineValue = $('.propertiesContentFieldOffline', activity.propertiesContent)
@@ -423,6 +426,8 @@
activity.items
.data('activity', activity)
.mousedown(HandlerLib.activityMousedownHandler)
+ //.touchstart(HandlerLib.activityMousedownHandler)
+ .touchmove(HandlerLib.dragItemsMoveHandler)
.click(HandlerLib.activityClickHandler)
.dblclick(HandlerLib.activityDblclickHandler)
.attr({
@@ -636,7 +641,7 @@
addSelectEffect : function (activity) {
// do not draw twice
if (!activity.items.selectEffect) {
- var box = activity.items.shape.getBBox();
+ var box = activity.items.getBBox();
// a simple rectange a bit wider than the actual activity boundaries
activity.items.selectEffect = paper.rect(
@@ -698,6 +703,9 @@
})
.toBack();
activity.items.push(activity.items.groupingEffect);
+
+ // this is needed, for some reason, otherwise the activity can not be selected
+ HandlerLib.resetCanvasMode();
}
},
Index: lams_central/web/includes/javascript/authoring/authoringHandler.js
===================================================================
diff -u -r3764cd835f0cd39d0a151f12185ae229e9aaff37 -rf9c27273356e1547373560d374e9b306295df2cb
--- lams_central/web/includes/javascript/authoring/authoringHandler.js (.../authoringHandler.js) (revision 3764cd835f0cd39d0a151f12185ae229e9aaff37)
+++ lams_central/web/includes/javascript/authoring/authoringHandler.js (.../authoringHandler.js) (revision f9c27273356e1547373560d374e9b306295df2cb)
@@ -72,7 +72,6 @@
* Start dragging an activity or transition.
*/
dragItemsStartHandler : function(items, draggedElement, mouseupHandler, event, startX, startY) {
- items.toFront();
// clear "clicked" flag, just in case
items.clicked = false;
@@ -120,6 +119,7 @@
* Moves dragged elements on the canvas.
*/
dragItemsMoveHandler : function(items, event, startX, startY) {
+ alert('bbb');
var dx = event.pageX - startX,
dy = event.pageY - startY;
Index: lams_central/web/includes/javascript/authoring/authoringMenu.js
===================================================================
diff -u -r3764cd835f0cd39d0a151f12185ae229e9aaff37 -rf9c27273356e1547373560d374e9b306295df2cb
--- lams_central/web/includes/javascript/authoring/authoringMenu.js (.../authoringMenu.js) (revision 3764cd835f0cd39d0a151f12185ae229e9aaff37)
+++ lams_central/web/includes/javascript/authoring/authoringMenu.js (.../authoringMenu.js) (revision f9c27273356e1547373560d374e9b306295df2cb)
@@ -342,7 +342,8 @@
if (paper) {
paper.clear();
} else {
- paper = Raphael('canvas');
+ // need to set size right away for Chrome
+ paper = Raphael('canvas', canvas.width() - 5, canvas.height() - 5);
}
resizePaper();
Index: lams_central/web/includes/javascript/jquery.ui.touch-punch.js
===================================================================
diff -u
--- lams_central/web/includes/javascript/jquery.ui.touch-punch.js (revision 0)
+++ lams_central/web/includes/javascript/jquery.ui.touch-punch.js (revision f9c27273356e1547373560d374e9b306295df2cb)
@@ -0,0 +1,11 @@
+/*
+ * jQuery UI Touch Punch 0.2.2
+ *
+ * Copyright 2011, Dave Furfero
+ * Dual licensed under the MIT or GPL Version 2 licenses.
+ *
+ * Depends:
+ * jquery.ui.widget.js
+ * jquery.ui.mouse.js
+ */
+(function(b){b.support.touch="ontouchend" in document;if(!b.support.touch){return;}var c=b.ui.mouse.prototype,e=c._mouseInit,a;function d(g,h){if(g.originalEvent.touches.length>1){return;}g.preventDefault();var i=g.originalEvent.changedTouches[0],f=document.createEvent("MouseEvents");f.initMouseEvent(h,true,true,window,1,i.screenX,i.screenY,i.clientX,i.clientY,false,false,false,false,0,null);g.target.dispatchEvent(f);}c._touchStart=function(g){var f=this;if(a||!f._mouseCapture(g.originalEvent.changedTouches[0])){return;}a=true;f._touchMoved=false;d(g,"mouseover");d(g,"mousemove");d(g,"mousedown");};c._touchMove=function(f){if(!a){return;}this._touchMoved=true;d(f,"mousemove");};c._touchEnd=function(f){if(!a){return;}d(f,"mouseup");d(f,"mouseout");if(!this._touchMoved){d(f,"click");}a=false;};c._mouseInit=function(){var f=this;f.element.bind("touchstart",b.proxy(f,"_touchStart")).bind("touchmove",b.proxy(f,"_touchMove")).bind("touchend",b.proxy(f,"_touchEnd"));e.call(f);};})(jQuery);
\ No newline at end of file