[gnome-boxes] Remove unused identifiers
- From: Zeeshan Ali Khattak <zeeshanak src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-boxes] Remove unused identifiers
- Date: Mon, 24 Oct 2011 21:19:33 +0000 (UTC)
commit 0e5b75459b4f68e280f7d20531f775a665bb4248
Author: Zeeshan Ali (Khattak) <zeeshanak gnome org>
Date: Tue Oct 25 00:14:26 2011 +0300
Remove unused identifiers
git has them in history so feel free to revive them when needed.
src/collection.vala | 9 ---------
src/util.vala | 22 ----------------------
src/wizard.vala | 2 +-
3 files changed, 1 insertions(+), 32 deletions(-)
---
diff --git a/src/collection.vala b/src/collection.vala
index 1138934..dff3e94 100644
--- a/src/collection.vala
+++ b/src/collection.vala
@@ -60,15 +60,6 @@ private class Boxes.CollectionSource: GLib.Object {
KeyFileFlags.KEEP_COMMENTS | KeyFileFlags.KEEP_TRANSLATIONS);
}
- private void save () {
- if (filename == null) {
- filename = make_filename (name);
- keyfile_save (keyfile, get_pkgconfig_source (filename));
- } else {
- keyfile_save (keyfile, get_pkgconfig_source (filename), true);
- }
- }
-
private string? get_string (string group, string key) {
try {
return keyfile.get_string (group, key);
diff --git a/src/util.vala b/src/util.vala
index b73af2e..6febb31 100644
--- a/src/util.vala
+++ b/src/util.vala
@@ -144,17 +144,6 @@ namespace Boxes {
return obj->stringval;
}
- private bool keyfile_save (KeyFile key_file, string file_name, bool overwrite = false) {
- if (!overwrite && FileUtils.test (file_name, FileTest.EXISTS))
- return false;
-
- var file = FileStream.open (file_name, "w");
- var data = key_file.to_data (null);
- file.puts (data);
-
- return true;
- }
-
public string replace_regex (string str, string old, string replacement) {
try {
var regex = new GLib.Regex (old);
@@ -165,17 +154,6 @@ namespace Boxes {
}
}
- private string make_filename (string name) {
- var filename = replace_regex (name, "[\\\\/:()<>|?*]", "_");
-
- var tryname = filename;
- for (var i = 0; FileUtils.test (tryname, FileTest.EXISTS); i++) {
- tryname = "%s-%d".printf (filename, i);
- }
-
- return tryname;
- }
-
private void actor_add (Clutter.Actor actor, Clutter.Container container) {
if (actor.get_parent () == (Clutter.Actor) container)
return;
diff --git a/src/wizard.vala b/src/wizard.vala
index 3026a12..58d5d00 100644
--- a/src/wizard.vala
+++ b/src/wizard.vala
@@ -204,7 +204,7 @@ private class Boxes.Wizard: Boxes.UI {
var text = this.source.url_entry.get_text ();
bool uncertain;
- var type = ContentType.guess (text, null, out uncertain);
+ ContentType.guess (text, null, out uncertain);
if (uncertain) {
var uri = Xml.URI.parse (text);
if (uri.scheme == "spice" || uri.scheme == "vnc") {
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]