bool CMsWin32Editbox::EditboxCreate( CMsWin32Window& parent , const CString& windowTitle , const bool createAsMultilineEdit , const Int32 xPosition , const Int32 yPosition , const UInt32 width , const UInt32 height , const bool readOnly ) {GUCEF_TRACE; if ( 0 != GetHwnd() ) { DestroyWindow( GetHwnd() ); SetHwnd( 0 ); } DWORD dwStyle = 0; if ( readOnly ) { dwStyle |= ES_READONLY; } if ( createAsMultilineEdit ) { dwStyle |= WS_VISIBLE|WS_CHILD|WS_BORDER|WS_VSCROLL|WS_HSCROLL|ES_MULTILINE|ES_WANTRETURN|ES_AUTOHSCROLL|ES_AUTOVSCROLL; SetHwnd( CreateWindow( "edit", windowTitle.C_String(), dwStyle, xPosition, yPosition, (int)width, (int)height, parent.GetHwnd(), (HMENU)this, GetCurrentModuleHandle(), (LPVOID)this ) ); } else { dwStyle |= WS_VISIBLE|WS_CHILD|WS_BORDER|ES_AUTOHSCROLL|ES_AUTOVSCROLL; SetHwnd( CreateWindow( "edit", windowTitle.C_String(), dwStyle, xPosition, yPosition, (int)width, (int)height, parent.GetHwnd(), (HMENU)this, GetCurrentModuleHandle(), (LPVOID)this ) ); } if ( GetHwnd() != 0 ) { HookWndProc(); return true; } return false; }
void CScriptBlip::SetName(CString sName) { RakNet::BitStream bitStream; bitStream.Write(GetEntity()->GetId()); bitStream.Write(RakNet::RakString(sName.C_String())); CServer::GetInstance()->GetNetworkModule()->Call(GET_RPC_CODEX(RPC_BLIP_SET_NAME), &bitStream, HIGH_PRIORITY, RELIABLE_ORDERED, -1, true); }
int SendPlayerMessageToAll(int * VM) { GET_SCRIPT_VM_SAFE; pVM->ResetStackIndex(); CString sMessage; pVM->Pop(sMessage); int iColor; pVM->Pop(iColor); bool bAllowFormatting; pVM->Pop(bAllowFormatting); RakNet::BitStream bitStream; bitStream.Write(RakNet::RakString(sMessage.C_String())); bitStream.Write((DWORD)iColor); bitStream.Write(bAllowFormatting); CServer::GetInstance()->GetNetworkModule()->Call(GET_RPC_CODEX(RPC_PLAYER_MESSAGE_TO_ALL), &bitStream, HIGH_PRIORITY, RELIABLE_ORDERED, -1, true); pVM->Push(true); return 1; }
void CBlipEntity::SetName(CString sName) { if (!m_uiBlip) return; EFLC::CScript::ChangeBlipNameFromAscii(m_uiBlip, sName.C_String()); m_sName = sName; }
bool CIniParser::LoadFrom( const CString& iniText ) {GUCEF_TRACE; CDynamicBuffer stringBuffer; stringBuffer.LinkTo( iniText.C_String(), iniText.Length() ); CDynamicBufferAccess stringBufferAccess( &stringBuffer, false ); return LoadFrom( stringBufferAccess ); }
bool CButtonImp::SetButtonText( const CString& newText ) {GUCEF_TRACE; if ( NULL != m_button ) { m_button->setCaption( newText.C_String() ); } return true; }
void* CSimplisticPluginLoadLogic::LoadPlugin( const CString& rootDir , const CString& moduleName , const CString& groupName , const TVersion* pluginVersion ) {GUCEF_TRACE; CString fullPluginPath = CombinePath( rootDir, moduleName ); fullPluginPath = RelativePath( fullPluginPath ); return LoadModuleDynamicly( fullPluginPath.C_String() ); }
bool CComboboxImp::SetText( const CString& text ) {GUCE_TRACE; if ( NULL != m_combobox ) { m_combobox->setText( text.C_String() ); return true; } return false; }
void CAndroidSystemLogger::LogWithoutFormatting( const TLogMsgType logMsgType , const Int32 logLevel , const CString& logMessage , const UInt32 threadId ) {GUCEF_TRACE; if ( NULL != m_logFunc ) { android_LogPriority androidLogPrio = LogTypeAndLevelToAndroidPrio( logMsgType, logLevel ); ( (TAndroidLogWriteFunc) m_logFunc )( androidLogPrio, m_tag.C_String(), logMessage.C_String() ); } }
bool CDStoreCodecPlugin::StoreDataTree( const CDataNode* tree , const CString& filename ) {GUCEF_TRACE; Create_Path_Directories( filename.C_String() ); CFileAccess access( filename, "wb" ); if ( access.IsValid() ) { return StoreDataTree( tree , &access ); } return false; }
void CX11Window::SetText( const CString& text ) {GUCEF_TRACE; if ( NULL != m_display && 0 != m_window ) { // We use the XTextProperty structure to store the title. ::XTextProperty windowName; windowName.value = (unsigned char*) text.C_String(); windowName.encoding = XA_STRING; windowName.format = 8; windowName.nitems = text.Length(); // Tell X to ask the window manager to set the window title. // X11 itself doesn't provide window title functionality. ::XSetWMName( m_display, m_window, &windowName ); } }
void CAndroidSystemLogger::Log( const TLogMsgType logMsgType , const Int32 logLevel , const CString& logMessage , const UInt32 threadId ) {GUCEF_TRACE; if ( NULL != m_logFunc ) { // Just use standard GUCEF log formatting CString formattedLogMsg = FormatStdLogMessage( logMsgType , logLevel , logMessage , threadId ); android_LogPriority androidLogPrio = LogTypeAndLevelToAndroidPrio( logMsgType, logLevel ); ( (TAndroidLogWriteFunc) m_logFunc )( androidLogPrio, m_tag.C_String(), formattedLogMsg.C_String() ); } }
void CMsWin32Editbox::SetText( const CString& text ) { SetWindowText( GetHwnd(), text.C_String() ); }