24 mTrackingService = trackingService;
25 connect(mTrackingService.get(), SIGNAL(activeToolChanged(
const QString&)),
this, SIGNAL(
changed()));
36 ToolPtr newTool = mTrackingService->getTool(value);
39 if(newTool == mTrackingService->getActiveTool())
41 mTrackingService->setActiveTool(newTool->getUid());
47 if (!mTrackingService->getActiveTool())
49 return qstring_cast(mTrackingService->getActiveTool()->getUid());
54 return "select the active tool";
62 for (TrackingService::ToolMap::iterator iter=tools.begin(); iter!=tools.end(); ++iter)
63 retval << iter->second->getUid();
69 ToolPtr tool = mTrackingService->getTool(
internal);
81 mTrackingService = trackingService;
84 this->activeToolChanged();
87 void StringPropertyActiveProbeConfiguration::activeToolChanged()
91 ToolPtr newTool = mTrackingService->getFirstProbe();
92 if (!newTool || !newTool->getProbe())
108 return "Probe Config";
115 mTool->getProbe()->applyNewConfigurationWithId(value);
123 return mTool->getProbe()->getConfigId();
128 return "Select a probe configuration for the active probe.";
134 return QStringList();
135 return mTool->getProbe()->getConfigIdList();
142 return mTool->getProbe()->getConfigName(
internal);
QString qstring_cast(const T &val)
virtual QStringList getValueRange() const
virtual QString getValue() const
get the data value.
boost::shared_ptr< class TrackingService > TrackingServicePtr
virtual QString convertInternal2Display(QString internal)
range of value. Use if data is constrained to a set.
virtual QString getHelp() const
return a descriptive help string for the data, used for example as a tool tip.
virtual bool setValue(const QString &value)
set the data value.
void activeToolChanged(const QString &uId)
void sectorChanged()
< Return a ProbeSectorPtr for the given uid. Use 'active' to get the default.
void changed()
emit when the underlying data value is changed: The user interface will be updated.
virtual QString getDisplayName() const
name of data entity. Used for display to user.
std::map< QString, ToolPtr > ToolMap
StringPropertyActiveProbeConfiguration(TrackingServicePtr trackingService)
Namespace for all CustusX production code.
boost::shared_ptr< class Tool > ToolPtr