~thomir-deactivatedaccount/unity/switcher-autopilot-test

« back to all changes in this revision

Viewing changes to plugins/unityshell/src/PreviewMusic.cpp

  • Committer: Didier Roche
  • Date: 2012-03-13 11:57:33 UTC
  • mto: This revision was merged to the branch mainline in revision 2126.
  • Revision ID: didier.roche@canonical.com-20120313115733-c85oulbsszhg2hmp
Xfixes.h is used by plugins/unityshell/src/PointerBarrier* but wasn't listed in the pc file configuration. It was picked by chance by another dep

Show diffs side-by-side

added added

removed removed

Lines of Context:
58
58
    void PreviewMusicAlbum::BuildLayout()
59
59
    {
60
60
      IconTexture *cover = new IconTexture (preview_->album_cover.c_str(), 400);
61
 
      nux::StaticCairoText *title = new nux::StaticCairoText(preview_->name, NUX_TRACKER_LOCATION);
 
61
      nux::StaticCairoText *title = new nux::StaticCairoText(preview_->name.c_str(), NUX_TRACKER_LOCATION);
62
62
      title->SetFont("Ubuntu 25");
63
63
 
64
64
      std::string artist_year = preview_->artist + ", " + preview_->year;
65
 
      nux::StaticCairoText *artist = new nux::StaticCairoText(artist_year, NUX_TRACKER_LOCATION);
 
65
      nux::StaticCairoText *artist = new nux::StaticCairoText(artist_year.c_str(), NUX_TRACKER_LOCATION);
66
66
      artist->SetFont("Ubuntu 15");
67
67
 
68
68
      std::ostringstream album_length_string;
71
71
                          << preview_->length / 60 << ":" << preview_->length % 60
72
72
                          << " " << _("min");
73
73
 
74
 
      nux::StaticCairoText *album_length = new nux::StaticCairoText(album_length_string.str(), NUX_TRACKER_LOCATION);
 
74
      nux::StaticCairoText *album_length = new nux::StaticCairoText(album_length_string.str().c_str(), NUX_TRACKER_LOCATION);
75
75
 
76
76
      std::ostringstream genres_string;
77
77
      dash::AlbumPreview::Genres::iterator genre_it;
86
86
        genres_string << (*genre_it);
87
87
      }
88
88
 
89
 
      nux::StaticCairoText *genres = new nux::StaticCairoText(genres_string.str(), NUX_TRACKER_LOCATION);
 
89
      nux::StaticCairoText *genres = new nux::StaticCairoText(genres_string.str().c_str(), NUX_TRACKER_LOCATION);
90
90
 
91
91
      nux::VLayout* tracks = new nux::VLayout(NUX_TRACKER_LOCATION);
92
92
 
112
112
        tracks->AddView(track_widget, 0, nux::MINOR_POSITION_LEFT, nux::MINOR_SIZE_FULL);
113
113
      }
114
114
 
115
 
      PreviewBasicButton* primary_button = new PreviewBasicButton(preview_->primary_action_name, NUX_TRACKER_LOCATION);
 
115
      PreviewBasicButton* primary_button = new PreviewBasicButton(preview_->primary_action_name.c_str(), NUX_TRACKER_LOCATION);
116
116
      //FIXME - add secondary action when we have the backend for it
117
117
      primary_button->state_change.connect ([&] (nux::View *view) { UriActivated.emit (preview_->primary_action_uri); });
118
118