The name of the initial branch for new projects is now "main" instead of "master". Existing projects remain unchanged. More information: https://doku.lrz.de/display/PUBLIC/GitLab

Commit c0d8a333 authored by schultezub's avatar schultezub
Browse files

some bug fixes for MSVC 2008

git-svn-id: https://camplinux.in.tum.de/svn/campvis/trunk@439 bb408c1c-ae56-11e1-83d9-df6b3e0c105e
parent 728c2946
......@@ -77,6 +77,8 @@ namespace campvis {
}
void DataContainerInspectorCanvas::init() {
initAllProperties();
GLJobProc.registerContext(this);
_paintShader = ShdrMgr.loadSeparate("core/glsl/passthrough.vert", "application/glsl/datacontainerinspector.frag", "", false);
_paintShader->setAttributeLocation(0, "in_Position");
......@@ -90,6 +92,8 @@ namespace campvis {
}
void DataContainerInspectorCanvas::deinit() {
deinitAllProperties();
if (_dataContainer != 0) {
_dataContainer->s_dataAdded.disconnect(this);
}
......
......@@ -209,6 +209,8 @@ namespace campvis {
void DataContainerInspectorWidget::deinit() {
if (_canvas != 0)
_canvas->deinit();
_pcWidget->updatePropCollection(0);
}
void DataContainerInspectorWidget::onDCTWidgetSelectionModelSelectionChanged(const QItemSelection& selected, const QItemSelection& deselected) {
......
......@@ -56,15 +56,17 @@ namespace campvis {
clearWidgetMap();
// create widgets for the new PropertyCollection
for (std::vector<AbstractProperty*>::const_iterator it = propertyCollection->getProperties().begin(); it != propertyCollection->getProperties().end(); ++it) {
QWidget* propWidget = PropertyWidgetFactory::createWidget(*it);
if (propWidget == 0)
propWidget = new QPushButton(QString::fromStdString((*it)->getTitle()));
if (propertyCollection != 0) {
for (std::vector<AbstractProperty*>::const_iterator it = propertyCollection->getProperties().begin(); it != propertyCollection->getProperties().end(); ++it) {
QWidget* propWidget = PropertyWidgetFactory::createWidget(*it);
if (propWidget == 0)
propWidget = new QPushButton(QString::fromStdString((*it)->getTitle()));
_widgetMap.insert(std::make_pair(*it, propWidget));
_layout->addWidget(propWidget);
propWidget->setVisible((*it)->isVisible());
(*it)->s_visibilityChanged.connect(this, &PropertyCollectionWidget::onPropertyVisibilityChanged);
_widgetMap.insert(std::make_pair(*it, propWidget));
_layout->addWidget(propWidget);
propWidget->setVisible((*it)->isVisible());
(*it)->s_visibilityChanged.connect(this, &PropertyCollectionWidget::onPropertyVisibilityChanged);
}
}
}
......
......@@ -72,7 +72,7 @@ namespace campvis {
void VtkImageReader::process(DataContainer& data) {
try {
std::ifstream file(p_url.getValue(), std::ifstream::in);
std::ifstream file(p_url.getValue().c_str(), std::ifstream::in);
if (!file.is_open() || file.bad())
throw tgt::FileException("Could not open file " + p_url.getValue() + " for reading.", p_url.getValue());
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment