Index: /trunk/hiptop/pester/locale/en_US/Pester.rsrc
===================================================================
--- /trunk/hiptop/pester/locale/en_US/Pester.rsrc	(revision 238)
+++ /trunk/hiptop/pester/locale/en_US/Pester.rsrc	(revision 239)
@@ -100,45 +100,68 @@
 		initialFocus
 
-	radioButton
-		title = "In"
-		id = ID_IN_BUTTON
-		positionBelow = ID_MESSAGE_FIELD : 5
-		alignRight = ID_MESSAGE_LABEL
+	groupBox
+		id = ID_IN_GROUP
+		onOffControl = ID_IN_BUTTON
+		onOffControlLeftPosition
+		positionBelow = ID_MESSAGE_LABEL : 7
+		fillToRight = 0
+		height = 22
 
-	numberEditor
-		# width = 50
-		id = ID_PERIOD_FIELD
-		dontWrap
-		minValue = 1
-		maxValue = 99
-		alignBaseline = ID_IN_BUTTON
-		positionToRight = ID_IN_BUTTON : 3
+		radioButton
+			id = ID_IN_BUTTON
+			title = "In"
+			event = EVENT_IN
+	
+		numberEditor
+			id = ID_PERIOD_FIELD
+			dontWrap
+			minValue = 1
+			maxValue = 99
+			alignBaseline = ID_IN_BUTTON
+			positionToRight = ID_IN_BUTTON : 1
+	
+		popupMenu
+			id = ID_PERIOD_UNITS_POPUP
+			menu = ID_PERIOD_UNITS_MENU
+			alignBaseline = ID_PERIOD_FIELD
+			positionToRight = ID_PERIOD_FIELD : 1
+		
+		checkBox
+			id = ID_PERIOD_REPEAT_BUTTON
+			title = "Repeat"
+			alignBaseline = ID_PERIOD_UNITS_POPUP
+			positionToRight = ID_PERIOD_UNITS_POPUP : 3
+	endGroupBox
 
-	popupMenu
-		menu = ID_PERIOD_UNITS_MENU
-		positionToRight = ID_PERIOD_FIELD : 3
-
-	radioButton
-		title = "At"
-		id = ID_AT_BUTTON
-		positionBelow = ID_PERIOD_FIELD : 5
-		alignRight = ID_MESSAGE_LABEL
-
-	dateEditor
-		id = ID_TIME_EDITOR
-		longTimeFormat
-		positionToRight = ID_AT_BUTTON : 3
-		alignBaseline = ID_AT_BUTTON
-
-	dateEditor
-		id = ID_DATE_EDITOR
-		positionToRight = ID_TIME_EDITOR : 1
-		alignBaseline = ID_AT_BUTTON
+	groupBox
+		id = ID_AT_GROUP
+		onOffControl = ID_AT_BUTTON
+		onOffControlLeftPosition
+		positionBelow = ID_IN_GROUP : 3
+		fillToRight = 0
+		height = 22
 	
-	datePicker
-		id = ID_DATE_PICKER
-		positionToRight = ID_DATE_EDITOR : 1
-		alignTop = ID_DATE_EDITOR
-
+		radioButton
+			title = "At"
+			id = ID_AT_BUTTON
+			event = EVENT_AT
+	
+		dateEditor
+			id = ID_TIME_EDITOR
+			longTimeFormat
+			alignBaseline = ID_AT_BUTTON
+			positionToRight = ID_AT_BUTTON : 1
+	
+		dateEditor
+			id = ID_DATE_EDITOR
+			positionToRight = ID_TIME_EDITOR : 1
+			alignBaseline = ID_TIME_EDITOR
+		
+		datePicker
+			id = ID_DATE_PICKER
+			positionToRight = ID_DATE_EDITOR : 1
+			alignTop = ID_DATE_EDITOR
+	endGroupBox
+	
 	button
 		id = ID_DISCARD_ALARM_BUTTON
Index: /trunk/hiptop/pester/net/sabi/pester/Alarm.java
===================================================================
--- /trunk/hiptop/pester/net/sabi/pester/Alarm.java	(revision 238)
+++ /trunk/hiptop/pester/net/sabi/pester/Alarm.java	(revision 239)
@@ -13,5 +13,5 @@
     // persisted
     private String mMessage;
-    private boolean mUsesPeriod;
+    private int mType;
     private long mPeriod;
     private Date mDate;
@@ -31,5 +31,5 @@
     }
     public boolean getUsesPeriod() {
-	return mUsesPeriod;
+	return mType != TYPE_DATE;
     }
     public Date getDate() {
@@ -40,10 +40,10 @@
 	mMessage = message;
     }
-    public void setPeriod(long period) {
-	mUsesPeriod = true;
+    public void setPeriod(long period, boolean repeating) {
+	mType = repeating ? TYPE_PERIODIC_REPEATING : TYPE_PERIODIC;
 	mPeriod = period;
     }
     public void setDate(Date date) {
-	mUsesPeriod = false;
+	mType = TYPE_DATE;
 	mDate = date;
     }
@@ -58,5 +58,5 @@
 	    dataStream.writeLong(mPeriod);
 	    dataStream.writeInt(mDate.getUnixTimeGMT());
-	    dataStream.writeBoolean(mUsesPeriod);
+	    dataStream.writeInt(mType);
 	    dataStream.flush();
 	    return byteStream.toByteArray();
@@ -78,5 +78,5 @@
 	    mMessage = dataStream.readUTF();
 	    mPeriod = dataStream.readLong();
-	    mUsesPeriod = dataStream.readBoolean();
+	    mType = dataStream.readInt();
 	} catch (Exception e) {
 	    // XXX do something
@@ -96,4 +96,8 @@
     }
 
+    public static final int TYPE_PERIODIC = 0;
+    public static final int TYPE_PERIODIC_REPEATING = 1;
+    public static final int TYPE_DATE = 2;
+
     public static final int STATUS_INVALID = 0;
     public static final int STATUS_EDITING = 1;
Index: /trunk/hiptop/pester/net/sabi/pester/AlarmListView.java
===================================================================
--- /trunk/hiptop/pester/net/sabi/pester/AlarmListView.java	(revision 238)
+++ /trunk/hiptop/pester/net/sabi/pester/AlarmListView.java	(revision 239)
@@ -6,4 +6,5 @@
 import danger.ui.Button;
 import danger.ui.DialogWindow;
+import danger.ui.RadioButton;
 import danger.ui.Rect;
 import danger.ui.TypeAheadTextField;
@@ -23,4 +24,5 @@
     private TypeAheadTextField sMessageField;
     private Button sDiscardAlarmButton;
+    private RadioButton sInButton, sAtButton;
 
     private static Alarm sFocusedAlarm, sEditingAlarm;
@@ -38,4 +40,6 @@
 	sMessageField = (TypeAheadTextField)sEditWindow.getDescendantWithID(ID_MESSAGE_FIELD);
 	sEditWindow.disableBottomRightButtonOnEmptyField(sMessageField);
+	sInButton = (RadioButton)sEditWindow.getDescendantWithID(ID_IN_BUTTON);
+	sAtButton = (RadioButton)sEditWindow.getDescendantWithID(ID_AT_BUTTON);
 	sDiscardAlarmButton = (Button)sEditWindow.getDescendantWithID(ID_DISCARD_ALARM_BUTTON);
 
@@ -87,4 +91,10 @@
 	    sAlarmList.removeItem(sFocusedAlarm);
 	    return true;
+	case EVENT_IN:
+	    sAtButton.setValue(0);
+	    return true;
+	case EVENT_AT:
+	    sInButton.setValue(0);
+	    return true;
 	}
 	return super.receiveEvent(e);
