child process - this holds all the GUI elements
436961
def child_task(self):
        ''''''
        mp_util.child_close_fds()

        from MAVProxy.modules.lib import wx_processguard
        from MAVProxy.modules.lib.wx_loader import wx
        from MAVProxy.modules.mavproxy_map.mp_slipmap_ui import MPSlipMapFrame

        state = self

        self.mt = mp_tile.MPTile(download=self.download,
                                 service=self.service,
                                 tile_delay=self.tile_delay,
                                 debug=self.debug,
                                 max_zoom=self.max_zoom)
        state.layers = {}
        state.info = {}
        state.need_redraw = True

        self.app = wx.App(False)
        self.app.SetExitOnFrameDelete(True)
        self.app.frame = MPSlipMapFrame(state=self)
        self.app.frame.Show()
        self.app.MainLoop()
492935
def main_loop():
    ''''''
    global grui, last_xlim
    while True:
        if mestate is None or mestate.exit:
            return
        while not mestate.input_queue.empty():
            line = mestate.input_queue.get()
            cmds = line.split(';')
            for c in cmds:
                process_stdin(c)

        for i in range(0, len(grui)):
            xlim = grui[i].check_xlim_change()
            if xlim is not None and mestate.settings.sync_xzoom:
                remlist = []
                for j in range(0, len(grui)):
                    #print("set_xlim: ", j, xlim)
                    if not grui[j].set_xlim(xlim):
                        remlist.append(j)
                last_xlim = xlim
                if len(remlist) > 0:
                    # remove stale graphs
                    new_grui = []
                    for j in range(0, len(grui)):
                        if j not in remlist:
                            new_grui.append(grui[j])
                    grui = new_grui
                break

        time.sleep(0.1)
221435
public function process()
    {
        parent::process();

        foreach ($this->children as $child) {
            if ($child !== null && !$child->isProcessed()) {
                $child->process();
            }
        }
    }
210966
function process( $tpl, &$text, $nspace, $current_nspace )
    {
        foreach( array_keys( $this->Children ) as $key )
        {
            $this->Children[$key]->process( $tpl, $text, $nspace, $current_nspace );
        }
    }
937973
void monitorChild() {
    Process proc = childProc;
    if (proc == null) {
      // Process may have already been disposed of, e.g. by calling kill().
      return;
    }

    while (proc.isAlive()) {
      try {
        proc.waitFor();
      } catch (Exception e) {
        LOG.log(Level.WARNING, "Exception waiting for child process to exit.", e);
      }
    }

    synchronized (this) {
      if (isDisposed()) {
        return;
      }

      int ec;
      try {
        ec = proc.exitValue();
      } catch (Exception e) {
        LOG.log(Level.WARNING, "Exception getting child process exit code, assuming failure.", e);
        ec = 1;
      }

      if (ec != 0) {
        State currState = getState();
        // Override state with failure if the current state is not final, or is success.
        if (!currState.isFinal() || currState == State.FINISHED) {
          setState(State.FAILED, true);
        }
      }

      dispose();
    }
  }
53006
def run(self, parent=None):
        
        self.cw = ConfigerWin(parent=parent)
        self.cw.show()
1103311
public void okToUseGui() {
        if (_mayUseGui) return;

        _mayUseGui = true;

        for (Object o : _children.keySet()) {
            if (o instanceof Visibility) {
                ((Visibility) o).okToUseGui();
            }
        }
    }
269475
def next_window(self, widget, data=None):
        
        # check whether deps-only is selected
        deps_only = ('deps_only' in self.args and self.args['deps_only']['checkbox'].get_active())

        # preserve argument value if it is needed to be preserved
        for arg_dict in [x for x in self.args.values() if 'preserved' in x['arg'].kwargs]:
            preserve_key = arg_dict['arg'].kwargs['preserved']
            # preserve entry text (string value)
            if 'entry' in arg_dict:
                if self.arg_is_selected(arg_dict):
                    config_manager.set_config_value(preserve_key, arg_dict['entry'].get_text())
            # preserve if checkbox is ticked (boolean value)
            else:
                config_manager.set_config_value(preserve_key, self.arg_is_selected(arg_dict))

        # save configuration into file
        config_manager.save_configuration_file()
        # get project directory and name
        project_dir = self.dir_name.get_text()
        full_name = self.get_full_dir_name()

        # check whether project directory and name is properly set
        if not deps_only and self.current_main_assistant.name == 'crt':
            if project_dir == "":
                return self.gui_helper.execute_dialog("Specify directory for project")
            else:
                # check whether directory is existing
                if not os.path.isdir(project_dir):
                    response = self.gui_helper.create_question_dialog(
                        "Directory {0} does not exists".format(project_dir),
                        "Do you want to create them?"
                    )
                    if response == Gtk.ResponseType.NO:
                        # User do not want to create a directory
                        return
                    else:
                        # Create directory
                        try:
                            os.makedirs(project_dir)
                        except OSError as os_err:
                            return self.gui_helper.execute_dialog("{0}".format(os_err))
                elif os.path.isdir(full_name):
                    return self.check_for_directory(full_name)

        if not self._build_flags():
            return

        if not deps_only and self.current_main_assistant.name == 'crt':
            self.kwargs['name'] = full_name
        self.kwargs['__ui__'] = 'gui_gtk+'

        self.data['kwargs'] = self.kwargs
        self.data['top_assistant'] = self.top_assistant
        self.data['current_main_assistant'] = self.current_main_assistant
        self.parent.run_window.open_window(widget, self.data)
        self.path_window.hide()
705091
def __get_gui_handle(self, root_dir):
        
        gui_path = os.path.join(root_dir, '.gui')
        fh = open(gui_path, "w+")
        return (gui_path, fh)
290154
def iter_all_children(self):
        '''
        '''
        
        if self.inline_child:
            yield self.inline_child
        for x in self.children:
            yield x
1299165
public void processAllChildren(TObjectProcedure<Cluster<T>> procedure) {
        if (children == null)
            return;
        for (Cluster<T> child : children) {
            procedure.execute(child);
            child.processAllChildren(procedure);
        }
    }
959048
def child_task(self):
        ''''''
        self.parent_pipe_send.close()
        
        from MAVProxy.modules.lib.wx_loader import wx
        from MAVProxy.modules.lib.wxhorizon_ui import HorizonFrame
        # Create wx application
        app = wx.App(False)
        app.frame = HorizonFrame(state=self, title=self.title)
        app.frame.SetDoubleBuffered(True)
        app.frame.Show()
        app.MainLoop()
        self.close_event.set()
748853
public final List<OSProcess> getChildren() {
            List<OSProcess> r = new ArrayList<OSProcess>();
            for (OSProcess p : ProcessTree.this)
                if(p.getParent()==this)
                    r.add(p);
            return r;
        }
648140
def child_task(self):
        ''''''
        mp_util.child_close_fds()
        from wx_loader import wx
        state = self

        self.app = wx.App(False)
        self.app.frame = MPImageFrame(state=self)
        self.app.frame.Show()
        self.app.MainLoop()
279168
public static void renderChildren(FacesContext fc, UIComponent component) throws IOException {
		for (Iterator<UIComponent> iterator = component.getChildren().iterator(); iterator.hasNext();) {
			UIComponent child = (UIComponent) iterator.next();
			renderChild(fc, child);
		}
	}
39372
public function process()
    {
        parent::process();

        if ($this->show_check_all) {
            $this->check_all->process();
        }

        // this is part of the old selection API
        $item_name = $this->getCheckboxRendererId();
        if (isset($_POST[$item_name]) && is_array($_POST[$item_name])) {
            $this->items = $_POST[$item_name];
        }
    }
547916
def main(self):
        
        self.loop = urwid.MainLoop(self.top, self.palettes[self.palette_names[0]], screen=self.tui,
                                   handle_mouse=False, input_filter=self.handle_keys,
                                   unhandled_input=self.unhandled)
        self.loop.run()