예제 #1
0
 void GuiCheckBox::setChecked( bool checked )
 {
     Assert( getGuiElement() );
     
     IGuiCheckBox_IPtr cbox = boost::static_pointer_cast<IGUICheckBox>( getGuiElement() );
     cbox->setChecked( checked );
 }
예제 #2
0
 bool GuiCheckBox::isChecked()
 {
     Assert( getGuiElement() );
     
     IGuiCheckBox_IPtr cbox = boost::static_pointer_cast<IGUICheckBox>( getGuiElement() );
     return cbox->isChecked();
 }
예제 #3
0
    int32_t GuiComboBox::addItem( const std::wstring& text )
    {
        Assert( getGuiElement() );

        // save the entry
        mEntries.push_back(text);

        // tell it to the irr gui
        IGuiComboBox_IPtr cbox = boost::static_pointer_cast<IGUIComboBox>( getGuiElement() );
        return cbox->addItem( mEntries.back().c_str() );
    }
예제 #4
0
void QuickSelectRingGui::remove(game::WeHandle h){
	for (auto it= icons.begin(); it!= icons.end(); ++it){
		//print(debug::Ch::Gui, debug::Vb::Trivial, "remove(..): before: guiElement= %x", &it->getGuiElement());
	}

	//int32 i=0;
	for (auto it= icons.begin(); it!= icons.end(); ++it){
		if (it->getGuiElement().getHandle() == h){
			//print(debug::Ch::Gui, debug::Vb::Trivial, "erase: %i, size: %i", i, icons.size());
			icons.erase(it);
			//print(debug::Ch::Gui, debug::Vb::Trivial, "size after: %i", icons.size());
			break;
		}
		//++i;
	}

	for (auto it= icons.begin(); it!= icons.end(); ++it){
		//print(debug::Ch::Gui, debug::Vb::Trivial, "after(..): before: guiElement= %x", &it->getGuiElement());
	}
}
예제 #5
0
 bool GuiText::GetWordWrap()
 {
     Assert( getGuiElement() );
     IGuiText_IPtr text = boost::static_pointer_cast<IGUIStaticText>( getGuiElement() );
     return text->isWordWrapEnabled();
 }
예제 #6
0
 void GuiText::SetWordWrap( bool wrap )
 {
     Assert( getGuiElement() );
     IGuiText_IPtr text = boost::static_pointer_cast<IGUIStaticText>( getGuiElement() );
     text->setWordWrap(wrap);
 }
예제 #7
0
 SColor GuiText::GetColor()
 {
     Assert( getGuiElement() );
     IGuiText_IPtr text = boost::static_pointer_cast<IGUIStaticText>( getGuiElement() );
     return text->getOverrideColor();
 }
예제 #8
0
 void GuiText::SetColor( const SColor& color )
 {
     Assert( getGuiElement() );
     IGuiText_IPtr text = boost::static_pointer_cast<IGUIStaticText>( getGuiElement() );
     text->setOverrideColor(color);
 }
예제 #9
0
 int32_t GuiComboBox::getSelected()
 {
     Assert( getGuiElement() );
     
     return (boost::static_pointer_cast<IGUIComboBox>(getGuiElement()))->getSelected();
 }