pub fn show_build_deps(deps: &mut Vec<String>, parent: &gtk::Window) -> bool {
	let dialog = gtk::MessageDialog::new::<gtk::Window>(Some(parent), DialogFlags::MODAL | DialogFlags::USE_HEADER_BAR, gtk::MessageType::Question, gtk::ButtonsType::OkCancel, "Build dependencies");
	let txt_deps = gtk::TextView::new();
	txt_deps.set_vexpand(true);
	txt_deps.set_hexpand(true);
    let should_trans = gtk::CheckButton::new_with_label("Translate deps");
    should_trans.set_active(true);
    dialog.get_content_area().pack_end(&should_trans, false, false, 0);
    dialog.get_content_area().pack_end(&txt_deps, false, false, 0);
    let buffer = txt_deps.get_buffer().unwrap();
    let org_text = deps.join("\n");
    buffer.set_text(&org_text);
    dialog.show_all();
    let resp = dialog.run();
    let new_text = buffer.get_text(&buffer.get_start_iter(), &buffer.get_end_iter(), false).unwrap().to_string();

    if resp == gtk::ResponseType::Ok {
    	*deps = {
    		println!("{:?}", new_text);
    		if should_trans.get_active() {
    			new_text.lines()
    			.filter_map(filter_and_trans)
    			.map(|(_, new_dep)| new_dep)
    			.map(|dep|if !dep.is_empty(){try_search_dep(dep)} else{dep})
    			.collect()
    		}
    		else {
    			new_text.lines().map(|dep|dep.to_string()).collect()
    		}
    	};
    }

    dialog.destroy();

    org_text != new_text
}
// True if modification has been made
True if modification has been made
True if modification has been made
pub fn show_build_deps(deps: &mut Vec<String>, parent: &gtk::Window) -> bool {
	let dialog = gtk::MessageDialog::new::<gtk::Window>(Some(parent), DialogFlags::MODAL | DialogFlags::USE_HEADER_BAR, gtk::MessageType::Question, gtk::ButtonsType::OkCancel, "Build dependencies");
	let txt_deps = gtk::TextView::new();
	txt_deps.set_vexpand(true);
	txt_deps.set_hexpand(true);
    let should_trans = gtk::CheckButton::new_with_label("Translate deps");
    should_trans.set_active(true);
    dialog.get_content_area().pack_end(&should_trans, false, false, 0);
    dialog.get_content_area().pack_end(&txt_deps, false, false, 0);
    let buffer = txt_deps.get_buffer().unwrap();
    let org_text = deps.join("\n");
    buffer.set_text(&org_text);
    dialog.show_all();
    let resp = dialog.run();
    let new_text = buffer.get_text(&buffer.get_start_iter(), &buffer.get_end_iter(), false).unwrap().to_string();
    if resp == gtk::ResponseType::Ok {
    	*deps = {
    		println!("{:?}", new_text);
    		if should_trans.get_active() {
    			new_text.lines()
    			.filter_map(filter_and_trans)
    			.map(|(_, new_dep)| new_dep)
    			.map(|dep|if !dep.is_empty(){try_search_dep(dep)} else{dep})
    			.collect()
    		}
    		else {
    			new_text.lines().map(|dep|dep.to_string()).collect()
    		}
    	};
    }
    dialog.destroy();
    org_text != new_text
}
pub fn show_build_deps ( deps : & mut Vec < String > , parent : & gtk :: Window ) -> bool { let dialog = gtk :: MessageDialog :: new :: < gtk :: Window > ( Some ( parent ) , DialogFlags :: MODAL | DialogFlags :: USE_HEADER_BAR , gtk :: MessageType :: Question , gtk :: ButtonsType :: OkCancel , " " ) ; let txt_deps = gtk :: TextView :: new ( ) ; txt_deps . set_vexpand ( true ) ; txt_deps . set_hexpand ( true ) ; let should_trans = gtk :: CheckButton :: new_with_label ( " " ) ; should_trans . set_active ( true ) ; dialog . get_content_area ( ) . pack_end ( & should_trans , false , false , 0 ) ; dialog . get_content_area ( ) . pack_end ( & txt_deps , false , false , 0 ) ; let buffer = txt_deps . get_buffer ( ) . unwrap ( ) ; let org_text = deps . join ( " \n " ) ; buffer . set_text ( & org_text ) ; dialog . show_all ( ) ; let resp = dialog . run ( ) ; let new_text = buffer . get_text ( & buffer . get_start_iter ( ) , & buffer . get_end_iter ( ) , false ) . unwrap ( ) . to_string ( ) ; if resp == gtk :: ResponseType :: Ok { * deps = { println ! ( " " new_text ) ; if should_trans . get_active ( ) { new_text . lines ( ) . filter_map ( filter_and_trans ) . map ( | ( _ , new_dep ) | new_dep ) . map ( | dep | if ! dep . is_empty ( ) { try_search_dep ( dep ) } else { dep } ) . collect ( ) } else { new_text . lines ( ) . map ( | dep | dep . to_string ( ) ) . collect ( ) } } ; } dialog . destroy ( ) ; org_text != new_text }
True if modification has been made
True if modification has been made
deps
&mut Vec<String>
parent
&gtk::Window