本文整理汇总了C++中ProjectConfiguration::git_remote_repository_url_get方法的典型用法代码示例。如果您正苦于以下问题:C++ ProjectConfiguration::git_remote_repository_url_get方法的具体用法?C++ ProjectConfiguration::git_remote_repository_url_get怎么用?C++ ProjectConfiguration::git_remote_repository_url_get使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类ProjectConfiguration
的用法示例。
在下文中一共展示了ProjectConfiguration::git_remote_repository_url_get方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: on_assistant_prepare
void RemoteRepositoryAssistant::on_assistant_prepare (GtkWidget *page)
{
extern Settings * settings;
ProjectConfiguration *projectconfig = settings->projectconfig(bible);
if (page == checkbutton_use_repository) {
// Set all values in the GUI, according to the project configuration if it is a Bible,
// or the general configuration for project notes.
// Whether to use the remote repository.
bool use_remote_repository = false;
if (bible_notes_selector_bible ()) {
use_remote_repository = projectconfig->git_use_remote_repository_get();
} else {
use_remote_repository = settings->genconfig.consultation_notes_git_use_remote_repository_get();
}
gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(checkbutton_use_repository), use_remote_repository);
// Set the repository location.
ustring repository_url;
if (bible_notes_selector_bible ()) {
repository_url = projectconfig->git_remote_repository_url_get();
} else {
repository_url = settings->genconfig.consultation_notes_git_remote_repository_url_get();
}
ignore_entry_repository_changed = true;
gtk_entry_set_text (GTK_ENTRY (entry_repository), repository_url.c_str());
ignore_entry_repository_changed = false;
}
if (page == label_try_git) {
// Prepare for the page to try git.
if (!git_tried_and_okay) {
git_tried_and_okay = try_git ();
if (git_tried_and_okay) {
gtk_assistant_set_page_complete (GTK_ASSISTANT (assistant), label_try_git, true);
}
}
}
if (page == vbox_repository) {
// Prepare for the page where the repository URL is set.
gtk_widget_grab_focus (entry_repository);
on_entry_repository();
}
if (page == vbox_clone) {
// Prepare for the page where the cloning is done.
if (repository_url_get() != previously_cloned_url) {
repository_unclone();
}
gtk_assistant_set_page_complete (GTK_ASSISTANT (assistant), vbox_clone, repository_was_cloned());
if (!repository_was_cloned()) {
gtk_label_set_text (GTK_LABEL (label_clone), "");
}
}
if (page == label_write_test) {
// Prepare for the page for testing write access.
if (!write_access_granted) {
test_write_access ();
}
}
}