You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: selector.rs
    path of file: ./repos/Fyrox/editor/src/scene
    
    the code of the file until where you have to start completion: use crate::utils::make_node_name;
use fyrox::graph::BaseSceneGraph;
use fyrox::graph::{SceneGraph, SceneGraphNode};
use fyrox::{
    core::{
        algebra::Vector2, parking_lot::Mutex, pool::ErasedHandle, pool::Handle,
        reflect::prelude::*, type_traits::prelude::*, uuid_provider, visitor::prelude::*,
    },
    gui::{
        border::BorderBuilder,
        button::{ButtonBuilder, ButtonMessage},
        define_constructor, define_widget_deref,
        draw::DrawingContext,
        grid::{Column, GridBuilder, Row},
        message::{MessageDirection, OsEvent, UiMessage},
        scroll_viewer::ScrollViewerBuilder,
        scroll_viewer::ScrollViewerMessage,
        searchbar::{SearchBarBuilder, SearchBarMessage},
        stack_panel::StackPanelBuilder,
        text::TextBuilder,
        tree::{Tree, TreeBuilder, TreeRootBuilder, TreeRootMessage},
        widget::{Widget, WidgetBuilder, WidgetMessage},
        window::{Window, WindowBuilder, WindowMessage},
        BuildContext, Control, HorizontalAlignment, Orientation, Thickness, UiNode, UserInterface,
    },
};
use std::{
    ops::{Deref, DerefMut},
    sync::mpsc::Sender,
    sync::Arc,
};

#[derive(Debug, Clone, PartialEq, Eq)]
pub struct Hiera
    
    fn handle_routed_message(&mut self, ui: &mut UserInterface, message: &mut UiMessage) {
        self.window.handle_routed_message(ui, message);

        if let Some(ButtonMessage::Click) = message.data() {
            if message.destination() == self.ok {
                ui.send_message(NodeSelectorMessage::selection(
                    self.handle,
                    MessageDirection::FromWidget,
                    ui.node(self.selector)
                        .query_component::<NodeSelector>()
                        .unwrap()
                        .selected
                        .clone(),
                ));

                ui.send_message(WindowMessage::close(
                    self.handle,
                    MessageDirection::ToWidget,
                ));
            } else if message.destination() == self.cancel {
                ui.send_message(WindowMessage::close(
                    self.handle,
                    MessageDirection::ToWidget,
                ));
            }
        } else if let Some(msg) = message.data::<NodeSelectorMessage>() {
            if message.destination() == self.handle
                && message.direction() == MessageDirection::ToWidget
            {
                // Dispatch to inner selector.
                let mut msg = message.clone();
                msg.destination = self.selector;
                ui.send_message(msg);
            } else if message.destination() == self.selector
                && message.direction() == MessageDirection::FromWidget
            {
                // Enable "ok" button if selection is valid.
                if let NodeSelectorMessage::Selection(selection) = msg {
                    ui.send_message(WidgetMessage::enabled(
                        self.ok,
                        MessageDirection::ToWidget,
                        !selection.is_empty(),
                    ));
                }
            }
        }
    }