2012-03-11 10:11:29 -05:00
|
|
|
/*
|
|
|
|
* Copyright 2012, Casalinuovo Dario. All rights reserved.
|
2021-07-07 22:35:44 -05:00
|
|
|
* Copyright 2021, Jaidyn Levesque. All rights reserved.
|
2012-03-11 10:11:29 -05:00
|
|
|
* Distributed under the terms of the MIT License.
|
|
|
|
*
|
|
|
|
* Authors:
|
|
|
|
* Casalinuovo Dario
|
2021-07-07 22:35:44 -05:00
|
|
|
* Jaidyn Levesque <jadedctrl@teknik.io>
|
2012-03-11 10:11:29 -05:00
|
|
|
*/
|
2021-05-23 15:10:14 -05:00
|
|
|
#ifndef _USER_INFO_WINDOW_H
|
|
|
|
#define _USER_INFO_WINDOW_H
|
2012-03-11 10:11:29 -05:00
|
|
|
|
|
|
|
#include <Window.h>
|
|
|
|
#include <TextView.h>
|
|
|
|
#include <StringView.h>
|
2021-08-04 13:51:31 -05:00
|
|
|
|
2012-03-11 10:11:29 -05:00
|
|
|
#include "Observer.h"
|
2021-08-19 17:04:33 -05:00
|
|
|
#include "UserStatus.h"
|
2012-03-11 10:11:29 -05:00
|
|
|
|
|
|
|
class BitmapView;
|
2021-05-23 15:10:14 -05:00
|
|
|
class User;
|
2012-03-11 10:11:29 -05:00
|
|
|
|
2021-05-23 15:10:14 -05:00
|
|
|
|
|
|
|
class UserInfoWindow: public BWindow, public Observer {
|
2012-03-11 10:11:29 -05:00
|
|
|
public:
|
2021-05-23 15:10:14 -05:00
|
|
|
UserInfoWindow(User* user);
|
2021-08-04 13:51:31 -05:00
|
|
|
~UserInfoWindow();
|
2012-03-11 10:11:29 -05:00
|
|
|
|
|
|
|
virtual void MessageReceived(BMessage* message);
|
2021-05-23 15:10:14 -05:00
|
|
|
|
2021-08-04 13:51:31 -05:00
|
|
|
virtual void ObserveString(int32 what, BString string);
|
|
|
|
virtual void ObserveInteger(int32 what, int32 num);
|
|
|
|
virtual void ObservePointer(int32 what, void* ptr);
|
|
|
|
|
2012-03-11 10:11:29 -05:00
|
|
|
private:
|
2021-07-07 22:35:44 -05:00
|
|
|
void _InitInterface();
|
|
|
|
|
2021-08-04 13:51:31 -05:00
|
|
|
void _UpdateStatusViews(UserStatus status);
|
|
|
|
|
2021-05-23 15:10:14 -05:00
|
|
|
User* fUser;
|
2021-07-07 22:35:44 -05:00
|
|
|
|
2012-03-11 10:11:29 -05:00
|
|
|
BitmapView* fAvatar;
|
2021-07-07 22:35:44 -05:00
|
|
|
BStringView* fNameLabel;
|
2021-07-24 20:54:46 -05:00
|
|
|
BTextView* fIdLabel;
|
|
|
|
BitmapView* fStatusIcon;
|
2021-07-07 22:35:44 -05:00
|
|
|
BStringView* fStatusLabel;
|
|
|
|
BStringView* fTextStatusLabel;
|
2012-03-11 10:11:29 -05:00
|
|
|
};
|
|
|
|
|
2021-05-23 15:10:14 -05:00
|
|
|
#endif // _USER_INFO_WINDOW_H
|