diff options
Diffstat (limited to 'protocols/Xfire/src')
| -rw-r--r-- | protocols/Xfire/src/main.cpp | 40 | ||||
| -rw-r--r-- | protocols/Xfire/src/options.cpp | 16 | ||||
| -rw-r--r-- | protocols/Xfire/src/resource.h | 2 | 
3 files changed, 13 insertions, 45 deletions
diff --git a/protocols/Xfire/src/main.cpp b/protocols/Xfire/src/main.cpp index abebbf6341..679b671fab 100644 --- a/protocols/Xfire/src/main.cpp +++ b/protocols/Xfire/src/main.cpp @@ -2837,31 +2837,17 @@ void setBuddyStatusMsg(BuddyListEntry *entry,string statusmsg)  	if(IsContactMySelf(entry->username))
  		return;
 -
 -	if(strlen(entry->statusmsg.c_str())>5)
 -	{
 -		char* away=(char*)entry->statusmsg.c_str();
 -		if(
 -			(*(away)=='('
 -			&& *(away+1)=='A'
 -			&& *(away+2)=='F'
 -			&& *(away+3)=='K'
 -			&& *(away+4)==')')
 -			||
 -			(*(away)=='('
 -			&&*(away+1)=='A'
 -			&& *(away+2)=='B'
 -			&& *(away+3)=='S'
 -			&& *(away+4)==')')
 -			)
 -		{
 +	
 +	if (entry->statusmsg.length() > 5) {
 +		string afk = entry->statusmsg.substr(0,5);
 +		if (afk == "(AFK)" || afk == "(ABS)")
  			mystatus=ID_STATUS_AWAY;
 -		}
  	}
 -
 +	
  	//statusmsg umwandeln
 -	char * temp = mir_utf8decode((char*)entry->statusmsg.c_str(),NULL);
 -	if(temp==NULL) temp=(char*)entry->statusmsg.c_str();
 +	char *temp = mir_utf8decode((char*)entry->statusmsg.c_str(),NULL);
 +	if (temp==NULL)
 +		temp=(char*)entry->statusmsg.c_str();
  	//DBDeleteContactSetting(hContact, "CList", "StatusMsg");
  	DBWriteContactSettingWord(entry->hcontact, protocolname, "Status", mystatus);
 @@ -2901,18 +2887,18 @@ void setBuddyStatusMsg(BuddyListEntry *entry,string statusmsg)  		strncpy(status,temp2,97);
 -		if(strlen(entry->statusmsg.c_str())>0)
 +		if(!entry->statusmsg.empty())
  		{
  			strcat(status," - ");
  			strcat(status,temp);
  		}
 -		DBWriteContactSettingString(entry->hcontact, "CList", "StatusMsg", status );
 -		DBWriteContactSettingString(entry->hcontact, protocolname, "XStatusMsg", status );
 +		DBWriteContactSettingString(entry->hcontact, "CList", "StatusMsg", status);
 +		DBWriteContactSettingString(entry->hcontact, protocolname, "XStatusMsg", status);
  	}
  	else
  	{
 -		DBWriteContactSettingString(entry->hcontact, "CList", "StatusMsg", temp );
 -		DBWriteContactSettingString(entry->hcontact, protocolname, "XStatusMsg", temp );
 +		DBWriteContactSettingString(entry->hcontact, "CList", "StatusMsg", temp);
 +		DBWriteContactSettingString(entry->hcontact, protocolname, "XStatusMsg", temp);
  		DBWriteContactSettingByte(entry->hcontact, protocolname, "XStatusId", 1);
  		DBWriteContactSettingString(entry->hcontact, protocolname, "XStatusName", "");
  	}
 diff --git a/protocols/Xfire/src/options.cpp b/protocols/Xfire/src/options.cpp index 2cb78c3318..123efeea32 100644 --- a/protocols/Xfire/src/options.cpp +++ b/protocols/Xfire/src/options.cpp @@ -371,23 +371,11 @@ static BOOL CALLBACK DlgProcOpts3(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM  			SendDlgItemMessage( hwndDlg, IDC_NOMSG, CB_ADDSTRING, 0, (LPARAM)TranslateT("Messagebox" ));
  			SendDlgItemMessage( hwndDlg, IDC_NOMSG, CB_ADDSTRING, 0, (LPARAM)TranslateT("Popup" ));
 -			//iconslots auswahl einfügen
 -			SendDlgItemMessage( hwndDlg, IDC_CBGICO, CB_ADDSTRING, 0, (LPARAM)TranslateT("Advanced #1 (ICQ X-Status)" ));
 -			SendDlgItemMessage( hwndDlg, IDC_CBGICO, CB_ADDSTRING, 0, (LPARAM)TranslateT("Advanced #2" ));
 -			SendDlgItemMessage( hwndDlg, IDC_CBGICO, CB_ADDSTRING, 0, (LPARAM)TranslateT("Advanced #3" ));
 -			SendDlgItemMessage( hwndDlg, IDC_CBGICO, CB_ADDSTRING, 0, (LPARAM)TranslateT("Advanced #4" ));
 -			SendDlgItemMessage( hwndDlg, IDC_CBVICO, CB_ADDSTRING, 0, (LPARAM)TranslateT("Advanced #1 (ICQ X-Status)" ));
 -			SendDlgItemMessage( hwndDlg, IDC_CBVICO, CB_ADDSTRING, 0, (LPARAM)TranslateT("Advanced #2" ));
 -			SendDlgItemMessage( hwndDlg, IDC_CBVICO, CB_ADDSTRING, 0, (LPARAM)TranslateT("Advanced #3" ));
 -			SendDlgItemMessage( hwndDlg, IDC_CBVICO, CB_ADDSTRING, 0, (LPARAM)TranslateT("Advanced #4" ));
 -
  			//scanalways
  			SendDlgItemMessage( hwndDlg, IDC_SCANUPDATECB, CB_ADDSTRING, 0, (LPARAM)TranslateT("No" ));
  			SendDlgItemMessage( hwndDlg, IDC_SCANUPDATECB, CB_ADDSTRING, 0, (LPARAM)TranslateT("On every start" ));
  			SendDlgItemMessage( hwndDlg, IDC_SCANUPDATECB, CB_ADDSTRING, 0, (LPARAM)TranslateT("Daily" ));
 -			SendDlgItemMessage( hwndDlg, IDC_CBVICO, CB_SETCURSEL, DBGetContactSettingByte(NULL,protocolname,"voiceico",-1), 0);
 -			SendDlgItemMessage( hwndDlg, IDC_CBGICO, CB_SETCURSEL, DBGetContactSettingByte(NULL,protocolname,"gameico",-1), 0);
  			SendDlgItemMessage( hwndDlg, IDC_SCANUPDATECB, CB_SETCURSEL, DBGetContactSettingByte(NULL,protocolname,"scanalways",0), 0);
  			SendDlgItemMessage( hwndDlg, IDC_NOMSG, CB_SETCURSEL, nomsgboxsel[DBGetContactSettingByte(NULL,protocolname,"nomsgbox",0)], 0);
 @@ -563,10 +551,6 @@ static BOOL CALLBACK DlgProcOpts3(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM  					DBWriteContactSettingByte(NULL,protocolname,"nomsgbox",(BYTE)nomsgboxsel[SendDlgItemMessage(hwndDlg, IDC_NOMSG, CB_GETCURSEL, 0, 0)]);
 -					ccc=SendDlgItemMessage(hwndDlg, IDC_CBVICO, CB_GETCURSEL, 0, 0);
 -					DBWriteContactSettingByte(NULL,protocolname,"voiceico",(BYTE)ccc);
 -					ccc=SendDlgItemMessage(hwndDlg, IDC_CBGICO, CB_GETCURSEL, 0, 0);
 -					DBWriteContactSettingByte(NULL,protocolname,"gameico",(BYTE)ccc);
  					ccc=SendDlgItemMessage(hwndDlg, IDC_CLANGROUP, CB_GETCURSEL, 0, 0);
  					DBWriteContactSettingByte(NULL,protocolname,"mainclangroup",(BYTE)ccc);
  					ccc=SendDlgItemMessage(hwndDlg, IDC_FOFGROUP, CB_GETCURSEL, 0, 0);
 diff --git a/protocols/Xfire/src/resource.h b/protocols/Xfire/src/resource.h index 5d2cbd8a4e..bf720a50d6 100644 --- a/protocols/Xfire/src/resource.h +++ b/protocols/Xfire/src/resource.h @@ -44,8 +44,6 @@  #define IDD_OPT                         102
  #define IDD_UD 1000
  #define IDD_UD2 1001
 -#define IDC_CBGICO 1013
 -#define IDC_CBVICO 1015
  #define IDC_GROUPCONFIG                 1000
  #define IDC_GROUPMAIN                   1002
  #define IDC_KEEPALIVE                   1011
  | 
