Skip to content

Commit

Permalink
Fixed bug with profile select/multiselect and incorrect dates
Browse files Browse the repository at this point in the history
  • Loading branch information
keltonhalbert committed Jan 5, 2015
1 parent ea21077 commit 2a9a7f4
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 5 deletions.
10 changes: 6 additions & 4 deletions runsharp/full_gui.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
from PySide.QtGui import *
from PySide.QtWebKit import *
import datetime as date
import numpy as np
import sys


Expand Down Expand Up @@ -369,12 +370,13 @@ def complete_name(self):
else:
self.prof_idx = []
selected = self.profile_list.selectedItems()
for item in xrange(len(selected)):
#text = item.text()
if item in self.prof_idx:
for item in selected:
idx = self.profile_list.indexFromItem(item).row()
if idx in self.prof_idx:
continue
else:
self.prof_idx.append(item)
self.prof_idx.append(idx)

self.prof_time = selected[0].text()
self.prof_idx.sort()
self.skewApp()
Expand Down
2 changes: 1 addition & 1 deletion sharppy/viz/SPCWindow.py
Original file line number Diff line number Diff line change
Expand Up @@ -300,7 +300,7 @@ def initData(self):

## set the plot title that will be displayed in the Skew frame.
if self.model != "Observed" and self.model != "Archive":
self.plot_title = self.loc + ' ' + datetime.strftime(self.d.dates[self.current_idx], "%Y%m%d/%H%M") \
self.plot_title = self.loc + ' ' + datetime.strftime(self.d.dates[self.prof_idx[self.current_idx]], "%Y%m%d/%H%M") \
+ " (" + self.run + " " + self.model + ")"

if self.model == "SREF":
Expand Down

0 comments on commit 2a9a7f4

Please sign in to comment.