summaryrefslogtreecommitdiff
path: root/muse2/muse/app.cpp
diff options
context:
space:
mode:
authorTim E. Real <termtech@rogers.com>2010-12-18 03:01:21 +0000
committerTim E. Real <termtech@rogers.com>2010-12-18 03:01:21 +0000
commite7cc0ca7479cd4bca09963a1d843ecbae15898eb (patch)
tree63cac33dd793a0fb3e9e3de6ee5f01d24f47e682 /muse2/muse/app.cpp
parent72dd531044077595601cfaae63835e49f46ece15 (diff)
Fixed marker view crash. Fixed some memory leaks.
Diffstat (limited to 'muse2/muse/app.cpp')
-rw-r--r--muse2/muse/app.cpp54
1 files changed, 29 insertions, 25 deletions
diff --git a/muse2/muse/app.cpp b/muse2/muse/app.cpp
index e1a2f20c..5ea7c00d 100644
--- a/muse2/muse/app.cpp
+++ b/muse2/muse/app.cpp
@@ -1842,7 +1842,7 @@ void MusE::loadProjectFile1(const QString& name, bool songTemplate, bool loadAll
mixer2->move(config.mixer2.geometry.topLeft());
}
- showMarker(config.markerVisible);
+ //showMarker(config.markerVisible); // Moved below. Tim.
resize(config.geometryMain.size());
move(config.geometryMain.topLeft());
@@ -1864,30 +1864,34 @@ void MusE::loadProjectFile1(const QString& name, bool songTemplate, bool loadAll
// p3.3.53 Try this AFTER the song update above which does a mixer update... Tested OK - mixers resize properly now.
if (loadAll)
{
- if(mixer1)
- {
- if(mixer1->geometry().size() != config.mixer1.geometry.size())
- {
- //printf("MusE::loadProjectFile1 resizing mixer1 x:%d y:%d w:%d h:%d\n", config.mixer1.geometry.x(),
- // config.mixer1.geometry.y(),
- // config.mixer1.geometry.width(),
- // config.mixer1.geometry.height()
- // );
- mixer1->resize(config.mixer1.geometry.size());
- }
- }
- if(mixer2)
- {
- if(mixer2->geometry().size() != config.mixer2.geometry.size())
- {
- //printf("MusE::loadProjectFile1 resizing mixer2 x:%d y:%d w:%d h:%d\n", config.mixer2.geometry.x(),
- // config.mixer2.geometry.y(),
- // config.mixer2.geometry.width(),
- // config.mixer2.geometry.height()
- // );
- mixer2->resize(config.mixer2.geometry.size());
- }
- }
+ if(mixer1)
+ {
+ if(mixer1->geometry().size() != config.mixer1.geometry.size())
+ {
+ //printf("MusE::loadProjectFile1 resizing mixer1 x:%d y:%d w:%d h:%d\n", config.mixer1.geometry.x(),
+ // config.mixer1.geometry.y(),
+ // config.mixer1.geometry.width(),
+ // config.mixer1.geometry.height()
+ // );
+ mixer1->resize(config.mixer1.geometry.size());
+ }
+ }
+ if(mixer2)
+ {
+ if(mixer2->geometry().size() != config.mixer2.geometry.size())
+ {
+ //printf("MusE::loadProjectFile1 resizing mixer2 x:%d y:%d w:%d h:%d\n", config.mixer2.geometry.x(),
+ // config.mixer2.geometry.y(),
+ // config.mixer2.geometry.width(),
+ // config.mixer2.geometry.height()
+ // );
+ mixer2->resize(config.mixer2.geometry.size());
+ }
+ }
+
+ // Moved here from above due to crash with a song loaded and then File->New.
+ // Marker view list was not updated, had non-existent items from marker list (cleared in ::clear()).
+ showMarker(config.markerVisible);
}
}