summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/browser.h2
-rw-r--r--src/clock.h4
-rw-r--r--src/help.h4
-rw-r--r--src/lastfm.h4
-rw-r--r--src/lyrics.h4
-rw-r--r--src/media_library.cpp12
-rw-r--r--src/media_library.h2
-rw-r--r--src/menu.h15
-rw-r--r--src/outputs.h4
-rw-r--r--src/playlist.h2
-rw-r--r--src/playlist_editor.cpp13
-rw-r--r--src/playlist_editor.h2
-rw-r--r--src/screen.h4
-rw-r--r--src/search_engine.h2
-rw-r--r--src/sel_items_adder.h4
-rw-r--r--src/server_info.h4
-rw-r--r--src/song_info.h4
-rw-r--r--src/tag_editor.cpp10
-rw-r--r--src/tag_editor.h2
-rw-r--r--src/tiny_tag_editor.h4
-rw-r--r--src/visualizer.h4
21 files changed, 1 insertions, 105 deletions
diff --git a/src/browser.h b/src/browser.h
index 9affe26c..6d733713 100644
--- a/src/browser.h
+++ b/src/browser.h
@@ -58,8 +58,6 @@ class Browser : public Screen< NC::Menu<MPD::Item> >, public Filterable, public
virtual void reverseSelection();
virtual MPD::SongList getSelectedSongs();
- virtual NC::List *GetList() { return w; }
-
virtual bool isMergable() { return true; }
const std::string &CurrentDir() { return itsBrowsedDir; }
diff --git a/src/clock.h b/src/clock.h
index 37524e2b..f9736c19 100644
--- a/src/clock.h
+++ b/src/clock.h
@@ -44,10 +44,6 @@ class Clock : public Screen<NC::Window>
virtual void MouseButtonPressed(MEVENT) { }
virtual bool isTabbable() { return true; }
- virtual bool allowsSelection() { return false; }
-
- virtual NC::List *GetList() { return 0; }
-
virtual bool isMergable() { return true; }
protected:
diff --git a/src/help.h b/src/help.h
index dd3982f3..b5b89a9c 100644
--- a/src/help.h
+++ b/src/help.h
@@ -36,10 +36,6 @@ class Help : public Screen<NC::Scrollpad>
virtual void SpacePressed() { }
virtual bool isTabbable() { return true; }
- virtual bool allowsSelection() { return false; }
-
- virtual NC::List *GetList() { return 0; }
-
virtual bool isMergable() { return true; }
protected:
diff --git a/src/lastfm.h b/src/lastfm.h
index d2a9f3de..05e041a0 100644
--- a/src/lastfm.h
+++ b/src/lastfm.h
@@ -46,10 +46,6 @@ class Lastfm : public Screen<NC::Scrollpad>
virtual void EnterPressed() { }
virtual void SpacePressed() { }
- virtual bool allowsSelection() { return false; }
-
- virtual NC::List *GetList() { return 0; }
-
virtual bool isMergable() { return true; }
void Refetch();
diff --git a/src/lyrics.h b/src/lyrics.h
index e8284ae8..f71efc07 100644
--- a/src/lyrics.h
+++ b/src/lyrics.h
@@ -47,10 +47,6 @@ class Lyrics : public Screen<NC::Scrollpad>
virtual void EnterPressed() { }
virtual void SpacePressed();
- virtual bool allowsSelection() { return false; }
-
- virtual NC::List *GetList() { return 0; }
-
virtual bool isMergable() { return true; }
void Edit();
diff --git a/src/media_library.cpp b/src/media_library.cpp
index 9a0800c1..bc6d3bfa 100644
--- a/src/media_library.cpp
+++ b/src/media_library.cpp
@@ -436,18 +436,6 @@ void MediaLibrary::MouseButtonPressed(MEVENT me)
}
}
-NC::List *MediaLibrary::GetList()
-{
- if (w == Tags)
- return Tags;
- else if (w == Albums)
- return Albums;
- else if (w == Songs)
- return Songs;
- else // silence compiler
- return 0;
-}
-
/***********************************************************************/
std::string MediaLibrary::currentFilter()
diff --git a/src/media_library.h b/src/media_library.h
index 04019507..3b38cce1 100644
--- a/src/media_library.h
+++ b/src/media_library.h
@@ -56,8 +56,6 @@ class MediaLibrary : public Screen<NC::Window>, public Filterable, public HasSon
virtual void reverseSelection();
virtual MPD::SongList getSelectedSongs();
- virtual NC::List *GetList();
-
virtual bool isMergable() { return true; }
int Columns();
diff --git a/src/menu.h b/src/menu.h
index ed6628a8..093de1fc 100644
--- a/src/menu.h
+++ b/src/menu.h
@@ -33,22 +33,9 @@
namespace NC {
-/// List class is an interface for Menu class
-struct List
-{
- /// @return currently highlighted position
- virtual size_t Choice() const = 0;
-
- /// @see Menu::Empty()
- virtual bool Empty() const = 0;
-
- /// @see Menu::Size()
- virtual size_t Size() const = 0;
-};
-
/// This template class is generic menu capable of
/// holding any std::vector compatible values.
-template <typename T> struct Menu : public Window, public List
+template <typename T> struct Menu : public Window
{
struct Item
{
diff --git a/src/outputs.h b/src/outputs.h
index 501ca88a..92c2e9f6 100644
--- a/src/outputs.h
+++ b/src/outputs.h
@@ -42,10 +42,6 @@ class Outputs : public Screen< NC::Menu<MPD::Output> >
virtual void MouseButtonPressed(MEVENT);
virtual bool isTabbable() { return true; }
- virtual bool allowsSelection() { return false; }
-
- virtual NC::List *GetList() { return w; }
-
virtual bool isMergable() { return true; }
void FetchList();
diff --git a/src/playlist.h b/src/playlist.h
index 4702953a..562c1a7f 100644
--- a/src/playlist.h
+++ b/src/playlist.h
@@ -61,8 +61,6 @@ class Playlist : public Screen<NC::Window>, public Filterable, public HasSongs,
virtual void reverseSelection();
virtual MPD::SongList getSelectedSongs();
- virtual NC::List *GetList() { return w == Items ? Items : 0; }
-
virtual bool isMergable() { return true; }
bool isFiltered();
diff --git a/src/playlist_editor.cpp b/src/playlist_editor.cpp
index f98ac266..cee497b9 100644
--- a/src/playlist_editor.cpp
+++ b/src/playlist_editor.cpp
@@ -564,19 +564,6 @@ void PlaylistEditor::Locate(const std::string &name)
SwitchTo();
}
-NC::List *PlaylistEditor::GetList()
-{
- if (w == Playlists)
- return Playlists;
- else if (w == Content)
- return Content;
- else // silence compiler
- {
- assert(false);
- return 0;
- }
-}
-
namespace {//
std::string SongToString(const MPD::Song &s)
diff --git a/src/playlist_editor.h b/src/playlist_editor.h
index 1afb62dc..266a0417 100644
--- a/src/playlist_editor.h
+++ b/src/playlist_editor.h
@@ -57,8 +57,6 @@ class PlaylistEditor : public Screen<NC::Window>, public Filterable, public HasS
virtual void Locate(const std::string &);
- virtual NC::List *GetList();
-
virtual bool isMergable() { return true; }
void MoveSelectedItems(Playlist::Movement where);
diff --git a/src/screen.h b/src/screen.h
index 455551a5..d232d2a2 100644
--- a/src/screen.h
+++ b/src/screen.h
@@ -74,10 +74,6 @@ class BasicScreen
/// @see Screen::MouseButtonPressed()
virtual void MouseButtonPressed(MEVENT) { }
-
- /// @return pointer to instantiation of Menu template class
- /// cast to List if available or null pointer otherwise
- virtual NC::List *GetList() = 0;
/// When this is overwritten with a function returning true, the
/// screen will be used in tab switching.
diff --git a/src/search_engine.h b/src/search_engine.h
index fae889ab..a159c252 100644
--- a/src/search_engine.h
+++ b/src/search_engine.h
@@ -102,8 +102,6 @@ class SearchEngine : public Screen< NC::Menu<SEItem> >, public Filterable, publi
virtual void reverseSelection();
virtual MPD::SongList getSelectedSongs();
- virtual NC::List *GetList() { return w->Size() >= StaticOptions ? w : 0; }
-
virtual bool isMergable() { return true; }
void UpdateFoundList();
diff --git a/src/sel_items_adder.h b/src/sel_items_adder.h
index 4e37e76d..03758032 100644
--- a/src/sel_items_adder.h
+++ b/src/sel_items_adder.h
@@ -38,10 +38,6 @@ class SelectedItemsAdder : public Screen< NC::Menu<std::string> >
virtual void SpacePressed() { }
virtual void MouseButtonPressed(MEVENT);
- virtual bool allowsSelection() { return false; }
-
- virtual NC::List *GetList() { return w; }
-
virtual bool isMergable() { return false; }
protected:
diff --git a/src/server_info.h b/src/server_info.h
index 298a61a7..b58f706f 100644
--- a/src/server_info.h
+++ b/src/server_info.h
@@ -36,10 +36,6 @@ class ServerInfo : public Screen<NC::Scrollpad>
virtual void EnterPressed() { }
virtual void SpacePressed() { }
- virtual bool allowsSelection() { return false; }
-
- virtual NC::List *GetList() { return 0; }
-
virtual bool isMergable() { return false; }
protected:
diff --git a/src/song_info.h b/src/song_info.h
index 98c9c648..65220168 100644
--- a/src/song_info.h
+++ b/src/song_info.h
@@ -42,10 +42,6 @@ class SongInfo : public Screen<NC::Scrollpad>
virtual void EnterPressed() { }
virtual void SpacePressed() { }
- virtual bool allowsSelection() { return false; }
-
- virtual NC::List *GetList() { return 0; }
-
virtual bool isMergable() { return true; }
static const Metadata Tags[];
diff --git a/src/tag_editor.cpp b/src/tag_editor.cpp
index 91a817f8..27fe2d9b 100644
--- a/src/tag_editor.cpp
+++ b/src/tag_editor.cpp
@@ -892,16 +892,6 @@ MPD::SongList TagEditor::getSelectedSongs()
/***********************************************************************/
-NC::List *TagEditor::GetList()
-{
- if (w == LeftColumn)
- return LeftColumn;
- else if (w == Tags)
- return Tags;
- else
- return 0;
-}
-
bool TagEditor::isNextColumnAvailable()
{
if (w == LeftColumn)
diff --git a/src/tag_editor.h b/src/tag_editor.h
index a62c3e8c..bc00b77d 100644
--- a/src/tag_editor.h
+++ b/src/tag_editor.h
@@ -67,8 +67,6 @@ class TagEditor : public Screen<NC::Window>, public Filterable, public HasSongs,
virtual void reverseSelection();
virtual MPD::SongList getSelectedSongs();
- virtual NC::List *GetList();
-
virtual bool isMergable() { return true; }
bool isNextColumnAvailable();
diff --git a/src/tiny_tag_editor.h b/src/tiny_tag_editor.h
index c734646c..75349fb5 100644
--- a/src/tiny_tag_editor.h
+++ b/src/tiny_tag_editor.h
@@ -43,10 +43,6 @@ class TinyTagEditor : public Screen< NC::Menu<NC::Buffer> >
virtual void SpacePressed() { }
virtual void MouseButtonPressed(MEVENT);
- virtual bool allowsSelection() { return false; }
-
- virtual NC::List *GetList() { return 0; }
-
virtual bool isMergable() { return true; }
void SetEdited(const MPD::Song &);
diff --git a/src/visualizer.h b/src/visualizer.h
index b8ae9a97..8082be1a 100644
--- a/src/visualizer.h
+++ b/src/visualizer.h
@@ -48,10 +48,6 @@ class Visualizer : public Screen<NC::Window>
virtual void MouseButtonPressed(MEVENT) { }
virtual bool isTabbable() { return true; }
- virtual NC::List *GetList() { return 0; }
-
- virtual bool allowsSelection() { return false; }
-
virtual bool isMergable() { return true; }
void SetFD();