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: connect_selection_of_directories.rs
    path of file: ./repos/czkawka/czkawka_gui/src/connect_things
    
    the code of the file until where you have to start completion: use std::collections::HashSet;
use std::path::PathBuf;

use gdk4::{DragAction, FileList};
use gtk4::prelude::*;
use gtk4::{DropTarget, FileChooserNative, Notebook, Orientation, ResponseType, TreeView, Window};

#[cfg(target_family = "windows")]
use czkawka_core::common::normalize_windows_path;

use crate::flg;
use crate::gui_structs::gui_data::GuiData;
use crate::help_functions::{check_if_value_is_in_list_store, get_list_store, ColumnsExcludedDirectory, ColumnsIncludedDirectory};
use crate::notebook_enums::{to_note
    
fn connect_file_dialog(file_dialog_include_exclude_folder_selection: &FileChooserNative, include_tree_view: TreeView, exclude_tree_view: TreeView, notebook_upper: Notebook) {
    file_dialog_include_exclude_folder_selection.connect_response(move |file_chooser, response_type| {
        if response_type == ResponseType::Accept {
            let excluded_items;
            let tree_view = match to_notebook_upper_enum(notebook_upper.current_page().unwrap()) {
                NotebookUpperEnum::IncludedDirectories => {
                    excluded_items = false;
                    &include_tree_view
                }
                NotebookUpperEnum::ExcludedDirectories => {
                    excluded_items = true;
                    &exclude_tree_view
                }
                _ => panic!(),
            };

            let mut folders: Vec<PathBuf> = Vec::new();
            let g_files = file_chooser.files();
            for index in 0..g_files.n_items() {
                let file = &g_files.item(index);
                if let Some(file) = file {
                    let ss = file.clone().downcast::<gtk4::gio::File>().unwrap();
                    if let Some(path_buf) = ss.path() {
                        folders.push(path_buf);
                    }
                }
            }

            add_directories(tree_view, &folders, excluded_items);
        }
    });
}