mirror of https://github.com/BOINC/boinc.git
*** empty log message ***
svn path=/trunk/boinc/; revision=11419
This commit is contained in:
parent
4e4702d4e0
commit
b8587902fd
|
@ -11896,4 +11896,10 @@ Kevin 31 Oct 2006
|
|||
clientgui/
|
||||
sg_ViewTabPage.cpp
|
||||
|
||||
Kevin 31 Oct 2006
|
||||
- MGR: Fixed bug that prevented recently downloaded stat icons from being displayed
|
||||
|
||||
clientgui/
|
||||
sg_StatImageLoader.cpp/h
|
||||
|
||||
|
|
@ -222,19 +222,22 @@ void StatImageLoader::LoadStatIcon(wxBitmap& image) {
|
|||
SetSize(width, height);
|
||||
}
|
||||
|
||||
|
||||
void StatImageLoader::LoadImage() {
|
||||
std::string StatImageLoader::GetProjectIconLoc() {
|
||||
char urlDirectory[256];
|
||||
std::string dirProjectGraphic;
|
||||
|
||||
CSkinSimple* pSkinSimple = wxGetApp().GetSkinManager()->GetSimple();
|
||||
CMainDocument* pDoc = wxGetApp().GetDocument();
|
||||
PROJECT* project = pDoc->state.lookup_project(m_prjUrl);
|
||||
url_to_project_dir((char*)project->master_url.c_str() ,urlDirectory);
|
||||
dirProjectGraphic = (std::string)urlDirectory + "/" + wxT("stat_icon");
|
||||
return (std::string)urlDirectory + "/" + wxT("stat_icon");
|
||||
}
|
||||
|
||||
|
||||
void StatImageLoader::LoadImage() {
|
||||
std::string dirProjectGraphic;
|
||||
|
||||
CSkinSimple* pSkinSimple = wxGetApp().GetSkinManager()->GetSimple();
|
||||
|
||||
char defaultIcnPath[256];
|
||||
if(boinc_resolve_filename(dirProjectGraphic.c_str(), defaultIcnPath, sizeof(defaultIcnPath)) == 0){
|
||||
if(boinc_resolve_filename(GetProjectIconLoc().c_str(), defaultIcnPath, sizeof(defaultIcnPath)) == 0){
|
||||
wxBitmap* btmpStatIcn = new wxBitmap();
|
||||
if ( btmpStatIcn->LoadFile(defaultIcnPath, wxBITMAP_TYPE_ANY) ) {
|
||||
LoadStatIcon(*btmpStatIcn);
|
||||
|
@ -251,7 +254,7 @@ void StatImageLoader::LoadImage() {
|
|||
void StatImageLoader::ReloadProjectSpecificIcon() {
|
||||
char defaultIcnPath[256];
|
||||
// Only update if it is project specific is found
|
||||
if(boinc_resolve_filename(projectIcon.c_str(), defaultIcnPath, sizeof(defaultIcnPath)) == 0){
|
||||
if(boinc_resolve_filename(GetProjectIconLoc().c_str(), defaultIcnPath, sizeof(defaultIcnPath)) == 0){
|
||||
wxBitmap* btmpStatIcn = new wxBitmap();
|
||||
if ( btmpStatIcn->LoadFile(defaultIcnPath, wxBITMAP_TYPE_ANY) ) {
|
||||
LoadStatIcon(*btmpStatIcn);
|
||||
|
|
|
@ -56,6 +56,7 @@ private:
|
|||
void ReloadProjectSpecificIcon();
|
||||
void BuildUserStatToolTip();
|
||||
void AddMenuItems();
|
||||
std::string GetProjectIconLoc();
|
||||
DECLARE_EVENT_TABLE()
|
||||
};
|
||||
|
||||
|
|
Loading…
Reference in New Issue