public boolean confirm(Runnable runnable) {
		boolean ret = false;
		
		// if the model has changed since the last save
		if(theModel.isDifferentFromFile()) {
			
			// loop while the user's decision hasn't been made.
			// this is here in case the user selects an erroneous
			// choice.  in that case, it will loop back around to
			// asking them what to do instead of defaulting to
			// dispose.
			boolean loop = false;
			do {
				
				// prompt with the save option
				int result = JOptionPane.showConfirmDialog(
					theView, 
					"do you want to save the changes to " + (theModel.getFile() == null ? "Untitled Calendar" : theModel.getFile().getName()), 
					"", 
					JOptionPane.YES_NO_CANCEL_OPTION, 
					JOptionPane.PLAIN_MESSAGE);
				switch(result) {
				
				// if they chose to save, "save" or "save as" 
				// depending on the state of the model's current file 
				case JOptionPane.YES_OPTION:
						
					// if there's no current file, prompt with a "save as"
					ret = save();
					loop = !ret;
					break;
					
				// if they chose not to save, continue with the dispose
				case JOptionPane.NO_OPTION:
					loop = false;
					ret = true;
					break;
					
				// if they chose to cancel, don't dispose
				case JOptionPane.CANCEL_OPTION:
					loop = false;
					break;
				}
			} while(loop);
			
		// if there's been no changes, open normally
		} else 
			ret = true;
		
		if(ret)
			runnable.run();
		return ret;
	}