fixed gcc4 warnings

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28022 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Stefano Ceccherini 2008-10-13 08:47:21 +00:00
parent 6545e08451
commit 099e08d534
3 changed files with 4 additions and 4 deletions

View File

@ -21,7 +21,7 @@
RefreshSlider::RefreshSlider(BRect frame, float min, float max, uint32 resizingMode)
: BSlider(frame, "Screen", "Refresh Rate:",
new BMessage(SLIDER_INVOKE_MSG), rintf(min * 10), rintf(max * 10),
new BMessage(SLIDER_INVOKE_MSG), (int32)rintf(min * 10), (int32)rintf(max * 10),
B_BLOCK_THUMB, resizingMode),
fStatus(new (std::nothrow) char[32])
{
@ -87,7 +87,7 @@ RefreshSlider::KeyDown(const char *bytes, int32 numBytes)
}
char*
const char*
RefreshSlider::UpdateText() const
{
if (fStatus != NULL)

View File

@ -20,7 +20,7 @@ class RefreshSlider : public BSlider {
virtual ~RefreshSlider();
virtual void DrawFocusMark();
virtual char* UpdateText() const;
virtual const char* UpdateText() const;
virtual void KeyDown(const char* bytes, int32 numBytes);
private:

View File

@ -41,7 +41,7 @@ RefreshWindow::RefreshWindow(BPoint position, float current, float min, float ma
rect.top += stringView->Bounds().Height() + 14;
fRefreshSlider = new RefreshSlider(rect, min, max, B_FOLLOW_TOP | B_FOLLOW_LEFT_RIGHT);
fRefreshSlider->SetValue(rint(current * 10));
fRefreshSlider->SetValue((int32)rintf(current * 10));
fRefreshSlider->SetModificationMessage(new BMessage(SLIDER_MODIFICATION_MSG));
float width, height;
fRefreshSlider->GetPreferredSize(&width, &height);