private void updateGrid() {
		CourseList model = super.getModel();
		Course course = model.getSelectedCourse();
		int firstYear = course.getFirstYearOfOffering();
		int latestYear = course.getLatestYearOfOffering();
		int yearRange = latestYear - firstYear + 1;
		GridBagLayout gridBag = new GridBagLayout();
		GridBagConstraints gbc = new GridBagConstraints();
		offeringsPanel.removeAll();
		offeringsPanel.setLayout(gridBag);
		for(int row = 0; row <= yearRange; row++) {
			for(int column = 0; column <= NUM_OF_SEMESTERS; column++) {
				gbc.fill = GridBagConstraints.BOTH;
				gbc.gridx = column;
				gbc.gridy = row;
				if(row == 0) {
					gbc.weightx = 1;
					gbc.weighty = 1;
					offeringsPanel.add(makeSemesterPanel(column));
				}
				else if(column == 0 && row > 0) {
					gbc.weightx = 0;
					gbc.weighty = 0;
					offeringsPanel.add(makeYearPanel(firstYear + row - 1), gbc);
				}
				else if(row >= 1 && column >= 1){
					gbc.weightx = 1;
					gbc.weighty = 1;
					offeringsPanel.add(makeOfferingButton(course, row, column), gbc);					
				}
			}
		}
		offeringsPanel.revalidate();
		offeringsPanel.repaint();
	}