public void sortTheList(String mode) {
		Vector<Track> sortedList = new Vector<Track>();
		int smallest = -1;
		float smallestValue = 0;
		while (tracksList.size() > 0) {
			for (int i = 0; i < tracksList.size(); i++) {
				float relevantValue = 0;
				if (mode.equals("bpm"))
					relevantValue = tracksList.get(i).getBpm();
				if (mode.equals("keyFr"))
					relevantValue = tracksList.get(i).getKeyFr();
				if (mode.equals("frPerBpm"))
					relevantValue = tracksList.get(i).getFrPerBpm();
				if (mode.equals("close"))
					relevantValue = tracksList.get(i).closenessTo(currentTrack());
				if (smallestValue >= relevantValue || smallest == -1) {
					smallestValue = relevantValue;
					smallest = i;
				}
			}
			sortedList.add(tracksList.remove(smallest));
			smallest = -1;
		}
		for (int i = 0; i < sortedList.size(); i++)
			tracksList.add(sortedList.get(i));
		parent.cellsManager.updateList();
	}