Unterschiede

Hier werden die Unterschiede zwischen zwei Versionen gezeigt.

Link zu dieser Vergleichsansicht

nettalk:scripting:cppplugintutorial [2006/05/01 15:35]
213.103.152.18
nettalk:scripting:cppplugintutorial [2008/09/26 13:23] (aktuell)
84.184.172.104
Zeile 149: Zeile 149:
 <code cpp> <code cpp>
  
-LRESULT SendPlain(char *text){+LRESULT SendPlain(char *text) 
 +{
  return SendMessage(hNTalkHwnd,​ WM_SETTEXT, (WPARAM)(-1),​ (LPARAM)text);​  return SendMessage(hNTalkHwnd,​ WM_SETTEXT, (WPARAM)(-1),​ (LPARAM)text);​
 }// end #​SendPlain() }// end #​SendPlain()
Zeile 157: Zeile 158:
 }// end #​SendPlain() }// end #​SendPlain()
  
-LRESULT SendText(char *text, int FrameId){ +LRESULT SendText(char *text, int FrameId) 
- SendText( string(text) , FrameId);+
 + return ​SendText( string(text) , FrameId);
 }// end #SendText() }// end #SendText()
  
-LRESULT SendText(string text, int FrameId){+LRESULT SendText(string text, int FrameId) 
 +{ 
 + char numbuffer[11];​
  string str;  string str;
 + memset(numbuffer,​ 0, sizeof(numbuffer));​
  str=strPluginName;​  str=strPluginName;​
  str+="​ send ";  str+="​ send ";
Zeile 168: Zeile 173:
  str+=string( ","​ );  str+=string( ","​ );
  str+=text;  str+=text;
- SendMessage(hNTalkHwnd,​ WM_SETTEXT, (WPARAM)(-1),​ (LPARAM)str.c_str());​+ return ​SendMessage(hNTalkHwnd,​ WM_SETTEXT, (WPARAM)(-1),​ (LPARAM)str.c_str());​
 }// end #SendText() }// end #SendText()
  

Eigene Werkzeuge