Fix some style violations.
This commit is contained in:
parent
c67f1936c0
commit
4412809657
|
@ -18,7 +18,8 @@
|
||||||
|
|
||||||
Account::Account(bigtime_t instanceId, CayaProtocol* cayap,
|
Account::Account(bigtime_t instanceId, CayaProtocol* cayap,
|
||||||
const char* name, BHandler* target)
|
const char* name, BHandler* target)
|
||||||
: fIdentifier(instanceId),
|
:
|
||||||
|
fIdentifier(instanceId),
|
||||||
fName(name),
|
fName(name),
|
||||||
fProtocol(cayap),
|
fProtocol(cayap),
|
||||||
fMessenger(target),
|
fMessenger(target),
|
||||||
|
|
|
@ -17,7 +17,8 @@ static AccountManager* fInstance = NULL;
|
||||||
|
|
||||||
|
|
||||||
AccountManager::AccountManager()
|
AccountManager::AccountManager()
|
||||||
: fStatus(CAYA_OFFLINE)
|
:
|
||||||
|
fStatus(CAYA_OFFLINE)
|
||||||
{
|
{
|
||||||
TheApp* theApp = reinterpret_cast<TheApp*>(be_app);
|
TheApp* theApp = reinterpret_cast<TheApp*>(be_app);
|
||||||
RegisterObserver(theApp->GetMainWindow());
|
RegisterObserver(theApp->GetMainWindow());
|
||||||
|
|
|
@ -16,7 +16,8 @@
|
||||||
|
|
||||||
|
|
||||||
CayaProtocolAddOn::CayaProtocolAddOn(image_id image, const char* path)
|
CayaProtocolAddOn::CayaProtocolAddOn(image_id image, const char* path)
|
||||||
: fImage(image),
|
:
|
||||||
|
fImage(image),
|
||||||
fPath(path),
|
fPath(path),
|
||||||
fIcon(NULL)
|
fIcon(NULL)
|
||||||
{
|
{
|
||||||
|
|
|
@ -33,7 +33,8 @@
|
||||||
|
|
||||||
|
|
||||||
ChatWindow::ChatWindow(ContactLinker* cl)
|
ChatWindow::ChatWindow(ContactLinker* cl)
|
||||||
: BWindow(BRect(200, 200, 500, 500),
|
:
|
||||||
|
BWindow(BRect(200, 200, 500, 500),
|
||||||
cl->GetName().String(), B_DOCUMENT_WINDOW, 0),
|
cl->GetName().String(), B_DOCUMENT_WINDOW, 0),
|
||||||
fContactLinker(cl)
|
fContactLinker(cl)
|
||||||
{
|
{
|
||||||
|
|
|
@ -20,7 +20,8 @@
|
||||||
#include "CayaPreferences.h"
|
#include "CayaPreferences.h"
|
||||||
|
|
||||||
ContactLinker::ContactLinker(BString id, BMessenger msgn)
|
ContactLinker::ContactLinker(BString id, BMessenger msgn)
|
||||||
: fChatWindow(NULL),
|
:
|
||||||
|
fChatWindow(NULL),
|
||||||
fID(id),
|
fID(id),
|
||||||
fName(id),
|
fName(id),
|
||||||
fMessenger(msgn),
|
fMessenger(msgn),
|
||||||
|
|
|
@ -15,7 +15,8 @@
|
||||||
|
|
||||||
|
|
||||||
EditingFilter::EditingFilter(BTextView* view)
|
EditingFilter::EditingFilter(BTextView* view)
|
||||||
: BMessageFilter(B_ANY_DELIVERY, B_ANY_SOURCE, B_KEY_DOWN, NULL),
|
:
|
||||||
|
BMessageFilter(B_ANY_DELIVERY, B_ANY_SOURCE, B_KEY_DOWN, NULL),
|
||||||
_view(view)
|
_view(view)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
|
@ -8,6 +8,7 @@
|
||||||
|
|
||||||
#include "TheApp.h"
|
#include "TheApp.h"
|
||||||
|
|
||||||
|
|
||||||
int
|
int
|
||||||
main(int argc, char* argv[])
|
main(int argc, char* argv[])
|
||||||
{
|
{
|
||||||
|
|
|
@ -51,7 +51,8 @@ const uint32 kPreferences = 'WPRF';
|
||||||
|
|
||||||
|
|
||||||
MainWindow::MainWindow()
|
MainWindow::MainWindow()
|
||||||
: BWindow(BRect(0, 0, 300, 400), "Caya", B_DOCUMENT_WINDOW, 0)
|
:
|
||||||
|
BWindow(BRect(0, 0, 300, 400), "Caya", B_DOCUMENT_WINDOW, 0)
|
||||||
{
|
{
|
||||||
fStatusView = new StatusView("statusView");
|
fStatusView = new StatusView("statusView");
|
||||||
|
|
||||||
|
|
|
@ -41,6 +41,7 @@ Notifier::NotifyInteger(int32 what, int32 value)
|
||||||
fObserverList.ItemAt(i)->ObserveInteger(what, value);
|
fObserverList.ItemAt(i)->ObserveInteger(what, value);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void
|
void
|
||||||
Notifier::NotifyPointer(int32 what, void* ptr)
|
Notifier::NotifyPointer(int32 what, void* ptr)
|
||||||
{
|
{
|
||||||
|
|
|
@ -15,7 +15,8 @@
|
||||||
|
|
||||||
|
|
||||||
ProtocolLooper::ProtocolLooper(CayaProtocol* protocol)
|
ProtocolLooper::ProtocolLooper(CayaProtocol* protocol)
|
||||||
: BLooper(),
|
:
|
||||||
|
BLooper(),
|
||||||
fProtocol(protocol)
|
fProtocol(protocol)
|
||||||
{
|
{
|
||||||
Account* account = reinterpret_cast<Account*>(
|
Account* account = reinterpret_cast<Account*>(
|
||||||
|
|
|
@ -43,7 +43,8 @@ const float kDividerWidth = 1.0f;
|
||||||
|
|
||||||
|
|
||||||
ProtocolSettings::ProtocolSettings(CayaProtocolAddOn* addOn)
|
ProtocolSettings::ProtocolSettings(CayaProtocolAddOn* addOn)
|
||||||
: fAddOn(addOn),
|
:
|
||||||
|
fAddOn(addOn),
|
||||||
fTemplate(new BMessage())
|
fTemplate(new BMessage())
|
||||||
{
|
{
|
||||||
_Init();
|
_Init();
|
||||||
|
@ -151,7 +152,8 @@ ProtocolSettings::Load(const char* account, BView* parent)
|
||||||
menu = new BPopUpMenu(name);
|
menu = new BPopUpMenu(name);
|
||||||
for (int j = 0; curr.FindString("valid_value", j); j++) {
|
for (int j = 0; curr.FindString("valid_value", j); j++) {
|
||||||
BMenuItem* item
|
BMenuItem* item
|
||||||
= new BMenuItem(curr.FindString("valid_value", j), NULL);
|
= new BMenuItem(curr.FindString("valid_value", j),
|
||||||
|
NULL);
|
||||||
menu->AddItem(item);
|
menu->AddItem(item);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -246,11 +248,14 @@ ProtocolSettings::Load(const char* account, BView* parent)
|
||||||
control = new BTextControl(name, _T(desc), value, NULL);
|
control = new BTextControl(name, _T(desc), value, NULL);
|
||||||
if (secret) {
|
if (secret) {
|
||||||
dynamic_cast<BTextControl*>(control)->TextView()->HideTyping(true);
|
dynamic_cast<BTextControl*>(control)->TextView()->HideTyping(true);
|
||||||
dynamic_cast<BTextControl*>(control)->SetText(_T(value));
|
dynamic_cast<BTextControl*>(control)->SetText(
|
||||||
|
_T(value));
|
||||||
}
|
}
|
||||||
dynamic_cast<BTextControl*>(control)->SetDivider(kDividerWidth);
|
dynamic_cast<BTextControl*>(control)->SetDivider(
|
||||||
|
kDividerWidth);
|
||||||
} else {
|
} else {
|
||||||
BStringView* label = new BStringView("NA", _T(desc), B_WILL_DRAW);
|
BStringView* label = new BStringView("NA", _T(desc),
|
||||||
|
B_WILL_DRAW);
|
||||||
layout.Add(label);
|
layout.Add(label);
|
||||||
|
|
||||||
NotifyingTextView* textView
|
NotifyingTextView* textView
|
||||||
|
|
|
@ -28,7 +28,8 @@
|
||||||
|
|
||||||
|
|
||||||
Server::Server()
|
Server::Server()
|
||||||
: BMessageFilter(B_ANY_DELIVERY, B_ANY_SOURCE)
|
:
|
||||||
|
BMessageFilter(B_ANY_DELIVERY, B_ANY_SOURCE)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -74,15 +75,6 @@ Server::LoginAll()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
#if 0
|
|
||||||
void
|
|
||||||
Server::UpdateSettings(BMessage settings)
|
|
||||||
{
|
|
||||||
fProtocol->Protocol()->UpdateSettings(settings);
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
|
|
||||||
|
|
||||||
void
|
void
|
||||||
Server::SendProtocolMessage(BMessage* msg)
|
Server::SendProtocolMessage(BMessage* msg)
|
||||||
{
|
{
|
||||||
|
@ -250,7 +242,8 @@ Server::ImMessage(BMessage* msg)
|
||||||
if (linker) {
|
if (linker) {
|
||||||
if (msg->FindRef("ref", &ref) == B_OK) {
|
if (msg->FindRef("ref", &ref) == B_OK) {
|
||||||
// BPath fullPath(&ref);
|
// BPath fullPath(&ref);
|
||||||
//BBitmap *bitmap = ImageCache::GetImage(BString(fullPath.Path()), BString(fullPath.Path()));
|
// BBitmap* bitmap = ImageCache::GetImage(
|
||||||
|
// BString(fullPath.Path()), BString(fullPath.Path()));
|
||||||
BBitmap *bitmap = BTranslationUtils::GetBitmap(&ref);
|
BBitmap *bitmap = BTranslationUtils::GetBitmap(&ref);
|
||||||
linker->SetNotifyAvatarBitmap(bitmap);
|
linker->SetNotifyAvatarBitmap(bitmap);
|
||||||
} else
|
} else
|
||||||
|
|
|
@ -27,7 +27,8 @@
|
||||||
|
|
||||||
|
|
||||||
TheApp::TheApp()
|
TheApp::TheApp()
|
||||||
: BApplication(CAYA_SIGNATURE),
|
:
|
||||||
|
BApplication(CAYA_SIGNATURE),
|
||||||
fMainWin(NULL)
|
fMainWin(NULL)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
|
@ -10,6 +10,7 @@
|
||||||
|
|
||||||
WindowsManager* WindowsManager::fInstance = NULL;
|
WindowsManager* WindowsManager::fInstance = NULL;
|
||||||
|
|
||||||
|
|
||||||
WindowsManager::WindowsManager()
|
WindowsManager::WindowsManager()
|
||||||
{
|
{
|
||||||
fCurrentPoint.Set(40.0f, 40.0f);
|
fCurrentPoint.Set(40.0f, 40.0f);
|
||||||
|
|
Ŝarĝante…
Reference in New Issue