diff --git a/src/apps/haiku-depot/PackageInfoView.cpp b/src/apps/haiku-depot/PackageInfoView.cpp index 213482b0a7..73182fbdfa 100644 --- a/src/apps/haiku-depot/PackageInfoView.cpp +++ b/src/apps/haiku-depot/PackageInfoView.cpp @@ -660,9 +660,15 @@ public: fPackageVersionView->SetFont(&versionFont); fPackageVersionView->SetHighColor(kLightBlack); - fVoteUpIconView = new BitmapView("vote up icon"); + // TODO: User rating IDs to identify which rating to vote up or down + BMessage* voteUpMessage = new BMessage(MSG_VOTE_UP); + voteUpMessage->AddInt32("rating id", -1); + BMessage* voteDownMessage = new BMessage(MSG_VOTE_DOWN); + voteDownMessage->AddInt32("rating id", -1); + + fVoteUpIconView = new BitmapButton("vote up icon", voteUpMessage); fUpVoteCountView = new BStringView("up vote count", ""); - fVoteDownIconView = new BitmapView("vote down icon"); + fVoteDownIconView = new BitmapButton("vote down icon", voteDownMessage); fDownVoteCountView = new BStringView("up vote count", ""); fVoteUpIconView->SetBitmap( diff --git a/src/apps/haiku-depot/PackageInfoView.h b/src/apps/haiku-depot/PackageInfoView.h index 28cfb96263..ea871dda36 100644 --- a/src/apps/haiku-depot/PackageInfoView.h +++ b/src/apps/haiku-depot/PackageInfoView.h @@ -15,6 +15,11 @@ class PackageActionView; class PackageManager; class PagesView; +enum { + MSG_VOTE_UP = 'vtup', + MSG_VOTE_DOWN = 'vtdn', +}; + class PackageInfoView : public BGroupView { public: