From fc3cfa548453f3620dfbd7bac3a28a6d878116d1 Mon Sep 17 00:00:00 2001 From: Alexandre Cloutier Date: Thu, 8 May 2014 19:14:39 -0400 Subject: [PATCH] applied comments --- .../English.lproj/Localizable.strings | 5 +- .../Toolbars/SOGoAppointmentFolders.toolbar | 2 +- UI/Scheduler/UIxCalViewPrint.m | 2 +- UI/Templates/SchedulerUI/UIxCalViewPrint.wox | 29 +++------- UI/WebServerResources/SchedulerUI.css | 12 +++-- UI/WebServerResources/UIxCalViewPrint.css | 54 +++++++------------ UI/WebServerResources/UIxCalViewPrint.js | 54 ++++++------------- 7 files changed, 54 insertions(+), 104 deletions(-) diff --git a/UI/Scheduler/English.lproj/Localizable.strings b/UI/Scheduler/English.lproj/Localizable.strings index 422a19a57..8a67933e9 100644 --- a/UI/Scheduler/English.lproj/Localizable.strings +++ b/UI/Scheduler/English.lproj/Localizable.strings @@ -5,6 +5,7 @@ "Create a new event" = "Create a new event"; "Create a new task" = "Create a new task"; "Edit this event or task" = "Edit this event or task"; +"Print the current calendar view" = "Print the current calendar view"; "Delete this event or task" = "Delete this event or task"; "Go to today" = "Go to today"; "Switch to day view" = "Switch to day view"; @@ -117,7 +118,7 @@ "Name of the Calendar" = "Name of the Calendar"; "new" = "New"; -"printview" = "Print View"; +"Print view" = "Print view"; "edit" = "Edit"; "delete" = "Delete"; "proposal" = "Proposal"; @@ -147,8 +148,6 @@ /* Print view */ "LIST" = "List"; -"DAY" = "Daily"; -"WEEK" = "Weekly"; "Print Settings" = "Print Settings"; "Title:" = "Title:"; "Layout:" = "Layout:"; diff --git a/UI/Scheduler/Toolbars/SOGoAppointmentFolders.toolbar b/UI/Scheduler/Toolbars/SOGoAppointmentFolders.toolbar index 772bb4573..54a5eae10 100644 --- a/UI/Scheduler/Toolbars/SOGoAppointmentFolders.toolbar +++ b/UI/Scheduler/Toolbars/SOGoAppointmentFolders.toolbar @@ -41,7 +41,7 @@ onclick = "return printView();"; cssClass = "tbicon_print single-window-not-conditional"; image = "tb-mail-print-flat-24x24.png"; - label = "Print View"; + label = "Print view"; tooltip = "Print the current calendar view"; } ), ( { link = "#"; label="Delete"; diff --git a/UI/Scheduler/UIxCalViewPrint.m b/UI/Scheduler/UIxCalViewPrint.m index 0acd3e3f9..af94b9792 100644 --- a/UI/Scheduler/UIxCalViewPrint.m +++ b/UI/Scheduler/UIxCalViewPrint.m @@ -32,7 +32,7 @@ static NSArray *layoutItems = nil; { if (!layoutItems) { - layoutItems = [NSArray arrayWithObjects: @"LIST", @"DAY", @"WEEK", nil]; + layoutItems = [NSArray arrayWithObjects: @"LIST", @"Daily", @"Weekly", nil]; [layoutItems retain]; } diff --git a/UI/Templates/SchedulerUI/UIxCalViewPrint.wox b/UI/Templates/SchedulerUI/UIxCalViewPrint.wox index 298076100..cbee832c1 100644 --- a/UI/Templates/SchedulerUI/UIxCalViewPrint.wox +++ b/UI/Templates/SchedulerUI/UIxCalViewPrint.wox @@ -7,9 +7,7 @@ xmlns:uix="OGo:uix" xmlns:label="OGo:label" className="UIxPageFrame" - const:popup="YES" - const:cssFiles="datepicker.css" - const:jsFiles="datepicker.js" > + const:popup="YES">
@@ -42,23 +40,24 @@ - + - - - - - "; - else - parsedTask += ""; + parsedTask += ""; } parsedTask += ""; parsedTask += "
- - -
-
"+ dueDate.toLocaleString() + "
"+ dueDate.toGMTString() + "
"+ dueDate.toLocaleString() + "
" + task[2] + "
"; @@ -510,19 +495,16 @@ function onPrintLayoutListChange() { switch(selectedLayout) { case "0": // List view window.resizeTo(660,500); - ajustWindow(660,500); currentView = parentView; break; case "1": // Day view window.resizeTo(1010,500); - ajustWindow(1010,500); currentView = "dayview"; break; case "2": // Week view window.resizeTo(1010,500); - ajustWindow(1010,500); currentView = "weekview"; break; @@ -550,19 +532,13 @@ function onTasksCheck(checkBox) { document.getElementById("rightFrameTasks").style.display = 'none'; } -function onPrintDateCheck() { +/*function onPrintDateCheck() { var dateRange = document.getElementsByName("dateRange"); var customDate = document.getElementById("customDate"); for (var i = 0; i < dateRange.length; i++) if (dateRange[i].children[1].children[0].disabled == customDate.checked) dateRange[i].children[1].children[0].disabled = !customDate.checked; -} - -function onDisplayTimeFormatCheck(){ - var radioTimeFormat = document.getElementsByName("printTimeFormat"); - displayTime = (radioTimeFormat[0].checked ? true : false); - refreshContent(); -} +}*/ function onPrintCompletedTasksCheck(checkBox) { printCompletedTasks = (checkBox.checked ? 1 : 0); @@ -574,7 +550,7 @@ function onPrintNoDueDateTasksCheck(checkBox) { refreshTasks(); } -/************** Date picker functions *************/ +/************** Date picker functions ************* this.initTimeWidgets = function (widgets) { this.timeWidgets = widgets; @@ -583,13 +559,13 @@ this.initTimeWidgets = function (widgets) { //jQuery(widgets['start']['date']).change(onAdjustTime); - /*jQuery(widgets['startingDate']['date']).closest('.date').datepicker({autoclose: true, + jQuery(widgets['startingDate']['date']).closest('.date').datepicker({autoclose: true, weekStart: 0, endDate: lastDay, startDate: firstDay, setStartDate: lastDay, startView: 2, - position: "below-shifted-left"});*/ + position: "below-shifted-left"}); } this.onAdjustTime = function(event) { @@ -597,9 +573,9 @@ this.onAdjustTime = function(event) { } this.onAdjustDueTime = function(event) { - /*var dateDelta = (window.getStartDate().valueOf() - window.getShadowStartDate().valueOf()); + var dateDelta = (window.getStartDate().valueOf() - window.getShadowStartDate().valueOf()); var newDueDate = new Date(window.getDueDate().valueOf() + dateDelta); - window.setDueDate(newDueDate);*/ + window.setDueDate(newDueDate); window.timeWidgets['start']['date'].updateShadowValue(); } @@ -621,14 +597,14 @@ function onPrintClick(event) { function init() { initializePrintSettings(); - initializeWhatToPrint(); + //initializeWhatToPrint(); //initializeOptions(); $("cancelButton").observe("click", onPrintCancelClick); $("printButton").observe("click", onPrintClick); - // TODO : Selected and custom date must be implemented and finished. + /* TODO : Selected and custom date must be implemented and finished. document.getElementById("eventsTasks").disabled=true; - document.getElementById("customDate").disabled=true; + document.getElementById("customDate").disabled=true;*/ onPrintLayoutListChange(); } @@ -638,13 +614,13 @@ function initializePrintSettings() { $("printLayoutList").observe("change", onPrintLayoutListChange); } -function initializeWhatToPrint() { +/*function initializeWhatToPrint() { var widgets = {'start': {'date': $("startingDate")}, 'end': {'date': $("endingDate")}}; initTimeWidgets(widgets); onPrintDateCheck(); -} +}*/ /*function initializeOptions() { }*/