aboutsummaryrefslogtreecommitdiff
path: root/src/playlists-menu-item.vala
diff options
context:
space:
mode:
authorConor Curran <conor.curran@canonical.com>2011-03-11 15:16:09 +0000
committerConor Curran <conor.curran@canonical.com>2011-03-11 15:16:09 +0000
commit6b0f3ffcaf55d151d87f8dc60d16388b8f4557a2 (patch)
treea155128a12c7cf47ce15772906058910fa87ce1b /src/playlists-menu-item.vala
parente97cb2babe643545ac2ccc0484e3a5bc98dbfb2c (diff)
downloadayatana-indicator-sound-6b0f3ffcaf55d151d87f8dc60d16388b8f4557a2.tar.gz
ayatana-indicator-sound-6b0f3ffcaf55d151d87f8dc60d16388b8f4557a2.tar.bz2
ayatana-indicator-sound-6b0f3ffcaf55d151d87f8dc60d16388b8f4557a2.zip
applied Mikkel's suggestions
Diffstat (limited to 'src/playlists-menu-item.vala')
-rw-r--r--src/playlists-menu-item.vala5
1 files changed, 1 insertions, 4 deletions
diff --git a/src/playlists-menu-item.vala b/src/playlists-menu-item.vala
index 9dcb686..b3fd7c6 100644
--- a/src/playlists-menu-item.vala
+++ b/src/playlists-menu-item.vala
@@ -84,10 +84,7 @@ public class PlaylistsMenuitem : PlayerItem
private string? parse_icon_path (string path)
{
- if (path == "")return null;
- var icon_file = File.new_for_path (path);
- if (icon_file.get_path() == null)return null;
- return icon_file.get_basename().split(".")[0];
+ return ( path == "" ? null : Path.get_basename(path).split(".")[0] );
}
public void update_individual_playlist (PlaylistDetails new_detail)