This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
func didSelectDate(date:NSDate, inCell cell:DetailsTableViewCell){ | |
if labels[selectedIndexPath!.row] == "Start"{ // Start date selected | |
let newStartDate = date | |
defaults.setObject(newStartDate, forKey: "startDT") | |
let duration = (defaults.objectForKey("eventDuration") as! Int) ?? 10 | |
let doubleTimeDuration:Double = Double(duration * 60) //convert Int to Double for next calc. | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// add day word always for details view. | |
let dateFormatterDay = NSDateFormatter() | |
// get for day name as full word | |
dateFormatterDay.dateFormat = "EEEE" | |
let dayNameOfEvent = dateFormatterDay.stringFromDate(startDT) | |
if ( (day == "Today") || (day == "Tomorrow") ) { | |
day = day + ", " + dayNameOfEvent |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
case "record": | |
flagAutoRecord = true | |
defaults.setObject(flagAutoRecord, forKey: "flagAutoRecord") //sets flagAutoRecord for processing | |
print("p339 we in here? query: \(query)") | |
if let tabBarController = self.window!.rootViewController as? UITabBarController { | |
tabBarController.selectedIndex = 2 //main Dictate screen | |