]> git.mxchange.org Git - flightgear.git/blobdiff - src/GUI/dialog.cxx
Boris Koenig:
[flightgear.git] / src / GUI / dialog.cxx
index 6320cae288152246f0cec3666bfeadea53bb02fa..52f2fef76b0c43a9e1f17f6558a5e6aaca443bc1 100644 (file)
@@ -385,6 +385,20 @@ FGDialog::makeObject (SGPropertyNode * props, int parentWidth, int parentHeight)
         dial->setWrap(props->getBoolValue("wrap", true));
         setupObject(dial, props);
         return dial;
+    } else if (type == "textbox") {
+       int slider_width = props->getIntValue("slider", parentHeight);
+       if (slider_width==0) slider_width=20;
+       puLargeInput * puTextBox =
+                     new puLargeInput(x, y, x+width, x+height, 2, slider_width);
+       if  (props->hasValue("editable"))
+       {
+          if (props->getBoolValue("editable")==false)
+             puTextBox->disableInput();
+          else
+             puTextBox->enableInput();
+       }
+       setupObject(puTextBox,props);
+       return puTextBox; 
     } else if (type == "select") {
         vector<SGPropertyNode_ptr> value_nodes;
         SGPropertyNode * selection_node =