Skip to content

Commit

Permalink
Remove trailing white space
Browse files Browse the repository at this point in the history
  • Loading branch information
ib committed Feb 19, 2016
1 parent 587e9ff commit 802247e
Show file tree
Hide file tree
Showing 39 changed files with 195 additions and 212 deletions.
6 changes: 3 additions & 3 deletions ChangeLog
Expand Up @@ -76,7 +76,7 @@ Xarchiver changelog:
- Extracting files in encrypted archives with DnD no more fails since the password it's now asked.
- Better behaviour of the GUI while archive operations are in progress.
- Fixed unsuccessful open of rpm archives when the cpio archive was compressed with bzip2.c.
- Changed View Window title as the filename of the ASCII file whose content the user wants to see.
- Changed View Window title as the filename of the ASCII file whose content the user wants to see.
- Added ability to convert archives to self-extracting.
- The archive properties dialog and the ISO info window can be closed by hitting ESC.
- Fixed bug preventing to add files by drag and drop when no archive has been created.
Expand Down Expand Up @@ -115,7 +115,7 @@ Xarchiver changelog:
- Fixed some memory leaks but surely someone is left :)
- Fixed bug causing filenames with spaces inside the archive not being viewed.
- Fixed bug causing filenames with spaces in arj archives appear truncated in Xarchiver window.
- Fixed a bug preventing the file dialog to select more than one file when adding to arj archives.
- Fixed a bug preventing the file dialog to select more than one file when adding to arj archives.
- Fixed progress bar not appearing when adding only one big file to an archive.
- Fixed a bug causing Xarchiver to hang when opening empty zip archives.
- Fixed a bug causing Xarchiver to exit when opening a not supported archive directly from the command line.
Expand All @@ -137,7 +137,7 @@ Xarchiver changelog:
- The size columns are treated as uint instead as string so that sorting by size is possible now.
- The bottom window is now used for reporting messages to the user.
- Added a progress bar that shows the archive's operation progress.
- Greatly improved the zip password detection; if an archive contains 10 files and only the last one is password
- Greatly improved the zip password detection; if an archive contains 10 files and only the last one is password
protected Xarchiver will detect it (the same is true for arj).
- When you open or create a password protected archive a small padlock is shown in the window bottom right.
- Fixed an occasional crash when opening zip archives.
Expand Down
1 change: 0 additions & 1 deletion doc/xarchiver.css
Expand Up @@ -94,4 +94,3 @@ li
border-style: solid;
padding: 0.5em;
}

1 change: 0 additions & 1 deletion doc/xarchiver.xsl
Expand Up @@ -9,4 +9,3 @@
<xsl:param name="chunker.output.encoding" select="'UTF-8'"/>

</xsl:stylesheet>

2 changes: 1 addition & 1 deletion po/sq.po
@@ -1,4 +1,4 @@
# Albanian translation of xarchiver package.
# Albanian translation of xarchiver package.
# Copyright (C) 2006 THE xarchiver'S COPYRIGHT HOLDER
# This file is distributed under the same license as the xarchiver package.
# Besnik Bleta <besnik@programeshqip.org>, 2007.
Expand Down
7 changes: 3 additions & 4 deletions src/7zip.c
Expand Up @@ -83,7 +83,7 @@ void xa_get_7zip_line_content (gchar *line, gpointer data)
last_line = TRUE;
return;
}

linesize = strlen(line);
archive->nr_of_files++;

Expand All @@ -94,11 +94,11 @@ void xa_get_7zip_line_content (gchar *line, gpointer data)
/* Time */
line[19] = '\0';
item[3] = line + 11;

/* Permissions */
line[25] = '\0';
item[2] = line + 20;

/* Size */
for(a=26; a < linesize; ++a)
if(line[a] >= '0' && line[a] <= '9')
Expand Down Expand Up @@ -247,4 +247,3 @@ void xa_7zip_test (XArchive *archive)
list = g_slist_append(list,command);
xa_run_command (archive,list);
}

14 changes: 7 additions & 7 deletions src/add_dialog.c
Expand Up @@ -52,7 +52,7 @@ Add_dialog_data *xa_create_add_dialog()

label1 = gtk_label_new (_("Selection"));
gtk_notebook_set_tab_label (GTK_NOTEBOOK (add_dialog->notebook1), gtk_notebook_get_nth_page (GTK_NOTEBOOK (add_dialog->notebook1), 0), label1);

add_dialog->filechooserwidget1 = gtk_file_chooser_widget_new (GTK_FILE_CHOOSER_ACTION_OPEN);
gtk_box_pack_start (GTK_BOX (vbox1), add_dialog->filechooserwidget1, TRUE, TRUE,2);

Expand All @@ -75,7 +75,7 @@ Add_dialog_data *xa_create_add_dialog()
gtk_radio_button_set_group (GTK_RADIO_BUTTON (add_dialog->store_path), add_dialog->path_group);
add_dialog->path_group = gtk_radio_button_get_group (GTK_RADIO_BUTTON (add_dialog->store_path));
gtk_button_set_focus_on_click (GTK_BUTTON (add_dialog->store_path), FALSE);

add_dialog->no_store_path = gtk_radio_button_new_with_mnemonic (NULL, _("Do not store paths"));
gtk_box_pack_start (GTK_BOX (hbox1), add_dialog->no_store_path, FALSE, FALSE, 0);
gtk_radio_button_set_group (GTK_RADIO_BUTTON (add_dialog->no_store_path), add_dialog->path_group);
Expand All @@ -89,7 +89,7 @@ Add_dialog_data *xa_create_add_dialog()

label2 = gtk_label_new (_("Options"));
gtk_notebook_set_tab_label (GTK_NOTEBOOK (add_dialog->notebook1), gtk_notebook_get_nth_page (GTK_NOTEBOOK (add_dialog->notebook1), 1), label2);

hbox2 = gtk_hbox_new (TRUE, 10);
gtk_box_pack_start (GTK_BOX (add_dialog->option_notebook_vbox), hbox2, TRUE, TRUE, 0);
gtk_container_set_border_width (GTK_CONTAINER (hbox2), 5);
Expand Down Expand Up @@ -132,7 +132,7 @@ Add_dialog_data *xa_create_add_dialog()

label7 = gtk_label_new (_("Actions: "));
gtk_frame_set_label_widget (GTK_FRAME (frame4), label7);

hbox3 = gtk_hbox_new (TRUE, 10);
gtk_box_pack_start (GTK_BOX (add_dialog->option_notebook_vbox), hbox3, TRUE, TRUE, 0);
gtk_container_set_border_width (GTK_CONTAINER (hbox3), 5);
Expand Down Expand Up @@ -171,7 +171,7 @@ Add_dialog_data *xa_create_add_dialog()

label5 = gtk_label_new (_("Encryption: "));
gtk_frame_set_label_widget (GTK_FRAME (frame3), label5);

dialog_action_area1 = GTK_DIALOG (add_dialog->dialog1)->action_area;
gtk_button_box_set_layout (GTK_BUTTON_BOX (dialog_action_area1), GTK_BUTTONBOX_END);

Expand Down Expand Up @@ -235,7 +235,7 @@ void xa_set_add_dialog_options(Add_dialog_data *add_dialog,XArchive *archive)
gtk_widget_set_sensitive(label3,flag);
gtk_widget_set_sensitive(add_dialog->store_path,flag);
gtk_widget_set_sensitive(add_dialog->no_store_path,flag);

if (archive->type != XARCHIVETYPE_7ZIP)
g_signal_connect (G_OBJECT (add_dialog->update),"toggled",G_CALLBACK (add_update_fresh_toggled_cb) , add_dialog);

Expand All @@ -245,7 +245,7 @@ void xa_set_add_dialog_options(Add_dialog_data *add_dialog,XArchive *archive)
if (archive->type == XARCHIVETYPE_RAR || archive->type == XARCHIVETYPE_RAR5 || archive->type == XARCHIVETYPE_7ZIP)
flag = TRUE;
gtk_widget_set_sensitive(add_dialog->solid_archive,flag);

if (archive->type != XARCHIVETYPE_TAR && archive->type != XARCHIVETYPE_TAR_GZ && archive->type != XARCHIVETYPE_TAR_LZMA && archive->type != XARCHIVETYPE_TAR_XZ && archive->type != XARCHIVETYPE_TAR_BZ2 && archive->type != XARCHIVETYPE_TAR_LZOP)
{
flag = TRUE;
Expand Down
1 change: 0 additions & 1 deletion src/add_dialog.h
Expand Up @@ -62,4 +62,3 @@ void xa_select_files_to_add ( GtkButton* ,gpointer );
void xa_execute_add_commands (XArchive *archive,GSList *list,gchar *compression_string);
void fix_adjustment_value (GtkAdjustment *,gpointer );
#endif

16 changes: 8 additions & 8 deletions src/archive.c
Expand Up @@ -106,7 +106,7 @@ void xa_spawn_async_process (XArchive *archive, gchar *command)
ioc = g_io_channel_unix_new (archive->output_fd);
g_io_channel_set_encoding (ioc,NULL,NULL);
g_io_channel_set_flags (ioc,G_IO_FLAG_NONBLOCK,NULL);

if (xa_main_window)
g_io_add_watch (ioc, G_IO_IN|G_IO_PRI|G_IO_ERR|G_IO_HUP|G_IO_NVAL,xa_process_output,archive);
else
Expand All @@ -122,7 +122,7 @@ void xa_spawn_async_process (XArchive *archive, gchar *command)
}

/* TODO: workaround for bug #3235
*
*
* gchar *xa_split_command_line(XArchive *archive,GSList *list)
{
gchar *command = NULL;
Expand Down Expand Up @@ -223,7 +223,7 @@ static gboolean xa_process_output (GIOChannel *ioc,GIOCondition cond,gpointer da
xa_update_window_with_archive_entries (archive,NULL);
gtk_tree_view_set_model (GTK_TREE_VIEW(archive->treeview),archive->model);
g_object_unref (archive->model);

if (archive->type == XARCHIVETYPE_ZIP || archive->type == XARCHIVETYPE_RAR || archive->type == XARCHIVETYPE_RAR5 || archive->type == XARCHIVETYPE_ARJ)
gtk_widget_set_sensitive (comment_menu,TRUE);
else
Expand Down Expand Up @@ -295,7 +295,7 @@ void xa_clean_archive_structure (XArchive *archive)

entry = archive->root_entry;
xa_free_entry (archive,entry);

if (archive->column_types != NULL)
g_free(archive->column_types);

Expand All @@ -305,7 +305,7 @@ void xa_clean_archive_structure (XArchive *archive)
g_slist_free (archive->error_output);
archive->error_output = NULL;
}

if (archive->path != NULL)
g_free(archive->path);

Expand All @@ -320,7 +320,7 @@ void xa_clean_archive_structure (XArchive *archive)

if (archive->passwd != NULL)
g_free (archive->passwd);

if (archive->working_dir != NULL)
g_free (archive->working_dir);

Expand Down Expand Up @@ -617,7 +617,7 @@ gchar *xa_build_full_path_name_from_entry(XEntry *entry, XArchive *archive)
{
if (entry->is_dir)
dummy = g_string_prepend_c(dummy,'/');

dummy = g_string_prepend(dummy,entry->filename);
entry = entry->prev;
}
Expand Down Expand Up @@ -668,7 +668,7 @@ gboolean xa_detect_encrypted_archive (XArchive *archive)

file = fopen (archive->path,"r");
fread (magic,1,4,file);

fseek (file,6,SEEK_SET);
if (archive->type == XARCHIVETYPE_ZIP)
{
Expand Down
2 changes: 1 addition & 1 deletion src/archive.h
Expand Up @@ -142,7 +142,7 @@ struct _XArchive
open_func open_archive;
};

#define XA_CLIPBOARD (gdk_atom_intern_static_string ("XARCHIVER_OWN_CLIPBOARD"))
#define XA_CLIPBOARD (gdk_atom_intern_static_string ("XARCHIVER_OWN_CLIPBOARD"))
#define XA_INFO_LIST (gdk_atom_intern_static_string ("application/xarchiver-info-list"))

typedef enum
Expand Down
5 changes: 2 additions & 3 deletions src/arj.c
Expand Up @@ -67,7 +67,7 @@ void xa_get_arj_line_content (gchar *line, gpointer data)
}
if (arj_line == 4)
{
arj_line = 1;
arj_line = 1;
return;
}

Expand Down Expand Up @@ -265,5 +265,4 @@ void xa_arj_test (XArchive *archive)

list = g_slist_append(list,command);
xa_run_command (archive,list);
}

}
2 changes: 1 addition & 1 deletion src/bzip2.c
Expand Up @@ -103,7 +103,7 @@ void xa_open_bzip2_lzma (XArchive *archive)
executable = "lzop ";
len = 4;
} /* else fail? */


GType types[]= {GDK_TYPE_PIXBUF,G_TYPE_STRING,G_TYPE_UINT64,G_TYPE_UINT64,G_TYPE_POINTER};
archive->column_types = g_malloc0(sizeof(types));
Expand Down
6 changes: 3 additions & 3 deletions src/deb.c
Expand Up @@ -63,15 +63,15 @@ void xa_get_ar_line_content (gchar *line, gpointer data)
/* Permissions */
line[9] = '\0';
item[0] = line;

/* Owner */
for(n=12; n < linesize; ++n)
if(line[n] == ' ')
break;
line[n] = '\0';
item[1] = line+10;

/* Size */
/* Size */
for(++n; n < linesize; ++n)
if(line[n] >= '0' && line[n] <= '9')
break;
Expand All @@ -86,7 +86,7 @@ void xa_get_ar_line_content (gchar *line, gpointer data)
archive->dummy_size += g_ascii_strtoull(item[2],NULL,0);
a = ++n;

/* Date Modified */
/* Date Modified */
for(; n < linesize; ++n)
{
if(n == 38)
Expand Down
14 changes: 7 additions & 7 deletions src/extract_dialog.c
Expand Up @@ -261,7 +261,7 @@ void xa_set_extract_dialog_options(Extract_dialog_data *dialog_data,gint selecte
flag = FALSE;
gtk_widget_set_sensitive(dialog_data->fresh,flag);
gtk_widget_set_sensitive(dialog_data->update,flag);

if (archive->extraction_path == NULL)
{
archive_dir = gtk_combo_box_get_active_text (GTK_COMBO_BOX(prefs_window->combo_prefered_extract_dir));
Expand Down Expand Up @@ -433,7 +433,7 @@ Multi_extract_data *xa_create_multi_extract_dialog()

gtk_drag_dest_set (dialog_data->files_treeview,GTK_DEST_DEFAULT_ALL,drop_targets,1,GDK_ACTION_COPY | GDK_ACTION_MOVE | GDK_ACTION_LINK | GDK_ACTION_ASK);
g_signal_connect (G_OBJECT (dialog_data->files_treeview),"drag-data-received",G_CALLBACK (xa_multi_extract_dialog_drag_data_received),dialog_data);

hbox2 = gtk_hbox_new (TRUE,5);
gtk_box_pack_start (GTK_BOX (vbox1),hbox2,FALSE,TRUE,0);

Expand Down Expand Up @@ -503,7 +503,7 @@ Multi_extract_data *xa_create_multi_extract_dialog()
cancelbutton1 = gtk_button_new_from_stock ("gtk-cancel");
gtk_dialog_add_action_widget (GTK_DIALOG (dialog_data->multi_extract),cancelbutton1,GTK_RESPONSE_CANCEL);
GTK_WIDGET_SET_FLAGS (cancelbutton1,GTK_CAN_DEFAULT);

extract_button = gtk_button_new();
extract_image = xa_main_window_find_image("xarchiver-extract.png",GTK_ICON_SIZE_SMALL_TOOLBAR);
extract_hbox = gtk_hbox_new(FALSE,4);
Expand Down Expand Up @@ -578,7 +578,7 @@ void xa_add_files_liststore (gchar *file_path,Multi_extract_data *dialog)
return;

stat (file_path,&my_stat);
file_size = my_stat.st_size;
file_size = my_stat.st_size;
file_utf8 = g_filename_display_name (file_path);
path = xa_remove_level_from_path(file_utf8);
_file_utf8 = xa_remove_path_from_archive_name(file_utf8);
Expand Down Expand Up @@ -682,7 +682,7 @@ void xa_select_where_to_extract(SexyIconEntry *entry, SexyIconEntryPosition icon

current_path = gtk_entry_get_text(GTK_ENTRY(entry));
if (strlen(current_path) > 0)
gtk_file_chooser_set_current_folder(GTK_FILE_CHOOSER (file_selector),current_path);
gtk_file_chooser_set_current_folder(GTK_FILE_CHOOSER (file_selector),current_path);

response = gtk_dialog_run (GTK_DIALOG(file_selector));
if (response == GTK_RESPONSE_ACCEPT)
Expand Down Expand Up @@ -730,12 +730,12 @@ void xa_parse_multi_extract_archive(Multi_extract_data *dialog)

overwrite = gtk_toggle_button_get_active(GTK_TOGGLE_BUTTON(dialog->overwrite));
double fraction = 1.0 / dialog->nr;

if (pb != NULL)
gtk_widget_show_all(pb->progress_window);
else
pb = xa_create_progress_bar(FALSE,NULL);

percent=fraction;
do
{
Expand Down
3 changes: 1 addition & 2 deletions src/extract_dialog.h
Expand Up @@ -45,7 +45,7 @@ GtkWidget *hbox1,*hbox2,*hbox3,*vbox1,*vbox2,*vbox3,*vbox5;
GtkWidget *frame1,*frame2,*alignment1,*alignment2,*alignment3;
GtkWidget *dialog_action_area1,*cancel_button,*okbutton1,*extract_button,*extract_image,*extract_hbox,*extract_label;
GtkTooltips *option_tooltip;

Extract_dialog_data *xa_create_extract_dialog();
void xa_activate_entry(GtkToggleButton *,gpointer );
void fresh_update_toggled_cb (GtkToggleButton *, Extract_dialog_data *);
Expand All @@ -57,4 +57,3 @@ void xa_activate_remove_button (GtkTreeModel *, GtkTreePath *, GtkTreeIter *, Gt
void xa_add_files_liststore (gchar *, Multi_extract_data *);
void xa_parse_multi_extract_archive(Multi_extract_data *);
#endif

8 changes: 4 additions & 4 deletions src/gzip.c
Expand Up @@ -40,7 +40,7 @@ void xa_open_gzip (XArchive *archive)
archive->extract = extract[archive->type];

command = g_strconcat (tar, " tzvf " , archive->escaped_path, NULL );
archive->has_properties = archive->can_add = archive->can_extract = archive->has_test = TRUE;
archive->has_properties = archive->can_add = archive->can_extract = archive->has_test = TRUE;
archive->has_sfx = FALSE;
archive->dummy_size = 0;
archive->nr_of_files = 0;
Expand Down Expand Up @@ -77,7 +77,7 @@ void xa_open_gzip (XArchive *archive)

char *names[]= {(_("Compressed")),(_("Size")),(_("Ratio"))};
xa_create_liststore (archive,names);

command = g_strconcat ("gzip -l ",archive->escaped_path,NULL);
xa_spawn_async_process (archive,command);
g_free (command);
Expand Down Expand Up @@ -124,10 +124,10 @@ void xa_get_gzip_line_content (gchar *line, gpointer data)
line[n] = '\0';
item[2] = line + a;
n++;

line[linesize-1] = '\0';
filename = line+n;

basename = g_path_get_basename(filename);
if (basename == NULL)
basename = g_strdup(filename);
Expand Down
2 changes: 1 addition & 1 deletion src/gzip.h
Expand Up @@ -15,7 +15,7 @@
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Street #330, Boston, MA 02111-1307, USA.
*/

#ifndef GZIP_H
#define GZIP_H

Expand Down

0 comments on commit 802247e

Please sign in to comment.