MGR: In Simple View, show institution, science area and description if task has no slide show

svn path=/trunk/boinc/; revision=24658
This commit is contained in:
Charlie Fenton 2011-11-28 13:34:15 +00:00
parent 89692e1fbb
commit 6b14e1224e
5 changed files with 1192 additions and 1052 deletions

View File

@ -8696,3 +8696,12 @@ David 26 Nov 2011
ssim/
ssim.cpp
Charlie 28 Nov 2011
- MGR: In Simple View, if task has no slide show, then display the
institution, science area and description.
This is in progress: not yet finished.
clientgui/
sg_PanelBase.cpp,.h
sg_TaskPanel.cpp,.h

View File

@ -174,6 +174,15 @@ void CSimplePanelBase::OnPaint(wxPaintEvent& /*event*/) {
}
wxBitmap CSimplePanelBase::GetBackgroundBmp() {
if (!m_GotBGBitMap) {
MakeBGBitMap();
}
return m_TaskPanelBGBitMap;
}
void CSimplePanelBase::UpdateStaticText(CTransparentStaticText **whichText, wxString s) {
EllipseStringIfNeeded(s, *whichText);
if ((*whichText)->GetLabel() != s) {

View File

@ -70,6 +70,7 @@ class CSimplePanelBase : public wxPanel
void ReskinInterface();
virtual wxRect GetProgressRect() { return wxRect(0, 0, 0, 0); }
wxBitmap GetBackgroundBmp();
void UpdateStaticText(CTransparentStaticText **whichText, wxString s);
void EllipseStringIfNeeded(wxString& s, wxWindow *win);

File diff suppressed because it is too large Load Diff

View File

@ -38,6 +38,25 @@ typedef struct {
///////////////////////////////////////////////////////////////////////////
/// Class CTextBox
///////////////////////////////////////////////////////////////////////////////
class CTextBox : public wxTextCtrl
{
DECLARE_DYNAMIC_CLASS( CTextBox )
DECLARE_EVENT_TABLE()
public:
CTextBox();
CTextBox( wxWindow* parent);
void OnEraseBackground(wxEraseEvent& event);
virtual bool HasTransparentBackground() { return true; };
};
///////////////////////////////////////////////////////////////////////////
/// Class CSlideShowPanel
///////////////////////////////////////////////////////////////////////////////
class CSlideShowPanel : public wxPanel
{
@ -52,12 +71,17 @@ class CSlideShowPanel : public wxPanel
void OnSlideShowTimer(wxTimerEvent& WXUNUSED(event));
void AdvanceSlideShow(bool changeSlide, bool reload);
void OnPaint(wxPaintEvent& WXUNUSED(event));
void OnEraseBackground(wxEraseEvent& event);
private:
CTransparentStaticText* m_institution;
CTransparentStaticText* m_scienceArea;
wxTextCtrl* m_description;
wxTimer* m_ChangeSlideTimer;
wxBitmap m_SlideBitmap;
bool m_bCurrentSlideIsDefault;
bool m_bGotAllProjectsList;
ALL_PROJECTS_LIST m_AllProjectsList;
};