mirror of
https://github.com/clangen/musikcube.git
synced 2024-11-19 11:10:52 +00:00
- Removed bootstrap.sh, not used anymore
- Wired up automatic updating in browse view while syncing - Fixed bug where BrowseView may still have contents in the TrackListView after clearing the library.
This commit is contained in:
parent
452ecd7923
commit
cd87222118
@ -1,3 +1,6 @@
|
||||
#cmake -DCMAKE_BUILD_TYPE=Release .
|
||||
#cmake -DCMAKE_BUILD_TYPE=Debug .
|
||||
|
||||
cmake_minimum_required(VERSION 3.0)
|
||||
|
||||
project(musikbox)
|
||||
@ -16,7 +19,9 @@ ExternalProject_Add(taglib
|
||||
INSTALL_COMMAND make install
|
||||
)
|
||||
|
||||
set(CMAKE_CXX_FLAGS ${CMAKE_CXX_FLAGS} "-std=c++11 -fpermissive -g")
|
||||
set(CMAKE_CXX_FLAGS ${CMAKE_CXX_FLAGS} "-std=c++11 -fpermissive")
|
||||
set(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} -g")
|
||||
set(CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE} -O2")
|
||||
|
||||
set (BOOST_LIBS
|
||||
system
|
||||
@ -45,7 +50,7 @@ set (BOOST_LINK_LIBS
|
||||
set(CMAKE_MODULE_PATH ${CMAKE_CURRENT_SOURCE_DIR}
|
||||
${CMAKE_CURRENT_SOURCE_DIR}/Modules)
|
||||
|
||||
SET (CMAKE_BUILD_TYPE DEBUG)
|
||||
# SET (CMAKE_BUILD_TYPE DEBUG)
|
||||
set (LIBRARY_OUTPUT_PATH ${musikbox_SOURCE_DIR}/bin/plugins)
|
||||
set (EXECUTABLE_OUTPUT_PATH ${musikbox_SOURCE_DIR}/bin)
|
||||
|
||||
|
19
bootstrap.sh
19
bootstrap.sh
@ -1,19 +0,0 @@
|
||||
#!/bin/bash
|
||||
|
||||
rm CMakeCache.txt
|
||||
|
||||
rm -rf build
|
||||
rm -rf bin
|
||||
|
||||
mkdir -p bin/plugins
|
||||
mkdir build
|
||||
|
||||
mkdir build/release
|
||||
cd build/release/
|
||||
cmake -DCMAKE_BUILD_TYPE=Release ../../
|
||||
cd ../../
|
||||
|
||||
mkdir build/debug
|
||||
cd build/debug/
|
||||
cmake -DCMAKE_BUILD_TYPE=Debug ../../
|
||||
cd ../../
|
@ -59,6 +59,8 @@ BrowseLayout::BrowseLayout(
|
||||
: LayoutBase()
|
||||
, playback(playback) {
|
||||
this->library = library;
|
||||
this->library->Indexer()->TrackRefreshed.connect(this, &BrowseLayout::OnIndexerProgress);
|
||||
this->library->Indexer()->SynchronizeEnd.connect(this, &BrowseLayout::OnIndexerProgress);
|
||||
this->InitializeWindows();
|
||||
}
|
||||
|
||||
@ -118,6 +120,10 @@ void BrowseLayout::OnVisibilityChanged(bool visible) {
|
||||
}
|
||||
}
|
||||
|
||||
void BrowseLayout::OnIndexerProgress() {
|
||||
this->categoryList->Requery();
|
||||
}
|
||||
|
||||
void BrowseLayout::RequeryTrackList(ListWindow *view) {
|
||||
if (view == this->categoryList.get()) {
|
||||
DBID selectedId = this->categoryList->GetSelectedId();
|
||||
@ -128,6 +134,9 @@ void BrowseLayout::RequeryTrackList(ListWindow *view) {
|
||||
this->categoryList->GetFieldName(),
|
||||
selectedId)));
|
||||
}
|
||||
else {
|
||||
this->trackList->Clear();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -71,6 +71,7 @@ namespace musik {
|
||||
private:
|
||||
void InitializeWindows();
|
||||
|
||||
void OnIndexerProgress();
|
||||
void RequeryTrackList(ListWindow *view);
|
||||
|
||||
void OnCategoryViewSelectionChanged(
|
||||
|
@ -215,4 +215,4 @@ IScrollAdapter::EntryPtr TrackListView::Adapter::GetEntry(size_t index) {
|
||||
entry->SetAttrs(attrs);
|
||||
return entry;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user