Vim styleguides, small theme fix, be a bit more robust when handling random strings as image burning input.
This commit is contained in:
parent
ad7c7344cf
commit
8cbc349d13
@ -9,7 +9,7 @@ group {
|
|||||||
tag: "br" "\n";
|
tag: "br" "\n";
|
||||||
tag: "tab" "\t";
|
tag: "tab" "\t";
|
||||||
tag: "hilight" "+ font=Sans:style:Bold";
|
tag: "hilight" "+ font=Sans:style:Bold";
|
||||||
// Need any tags?
|
// Need any more tags?
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -91,8 +91,8 @@ group {
|
|||||||
program {
|
program {
|
||||||
name: "focus1";
|
name: "focus1";
|
||||||
action: FOCUS_SET;
|
action: FOCUS_SET;
|
||||||
signal: "mouse,down,*";
|
signal: "load";
|
||||||
source: "*";
|
source: "";
|
||||||
target: "label";
|
target: "label";
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -246,7 +246,6 @@ group {
|
|||||||
state: "default" 0.0;
|
state: "default" 0.0;
|
||||||
align: 0.5 0.5;
|
align: 0.5 0.5;
|
||||||
color: 255 255 255 0;
|
color: 255 255 255 0;
|
||||||
max: 245 99999;
|
|
||||||
|
|
||||||
rel1 {
|
rel1 {
|
||||||
to: "filelist_overlay";
|
to: "filelist_overlay";
|
||||||
@ -262,7 +261,6 @@ group {
|
|||||||
text: "";
|
text: "";
|
||||||
font: "ecdb/default";
|
font: "ecdb/default";
|
||||||
size: 24;
|
size: 24;
|
||||||
min: 1 1;
|
|
||||||
align: 0.5 0.5;
|
align: 0.5 0.5;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -1,3 +1,4 @@
|
|||||||
|
/* vim: set sw=3 ts=3 sts=3 expandtab: */
|
||||||
#include "ecdb.h"
|
#include "ecdb.h"
|
||||||
|
|
||||||
/* Global Variables */
|
/* Global Variables */
|
||||||
|
@ -1,3 +1,4 @@
|
|||||||
|
/* vim: set sw=3 ts=3 sts=3 expandtab: */
|
||||||
#ifndef ECDB_H
|
#ifndef ECDB_H
|
||||||
#define ECDB_H
|
#define ECDB_H
|
||||||
|
|
||||||
|
@ -1,3 +1,4 @@
|
|||||||
|
/* vim: set sw=3 ts=3 sts=3 expandtab: */
|
||||||
#include "ecdb.h"
|
#include "ecdb.h"
|
||||||
|
|
||||||
int transcode_data_cb(void *data, int type, void *event);
|
int transcode_data_cb(void *data, int type, void *event);
|
||||||
|
@ -1,3 +1,4 @@
|
|||||||
|
/* vim: set sw=3 ts=3 sts=3 expandtab: */
|
||||||
#ifndef ECDB_AUDIO_H
|
#ifndef ECDB_AUDIO_H
|
||||||
#define ECDB_AUDIO_H
|
#define ECDB_AUDIO_H
|
||||||
|
|
||||||
|
@ -1,3 +1,4 @@
|
|||||||
|
/* vim: set sw=3 ts=3 sts=3 expandtab: */
|
||||||
#include "ecdb.h"
|
#include "ecdb.h"
|
||||||
|
|
||||||
typedef struct Burn_Data Burn_Data;
|
typedef struct Burn_Data Burn_Data;
|
||||||
|
@ -1,3 +1,4 @@
|
|||||||
|
/* vim: set sw=3 ts=3 sts=3 expandtab: */
|
||||||
#ifndef ECDB_BURN_H
|
#ifndef ECDB_BURN_H
|
||||||
#define ECDB_BURN_H
|
#define ECDB_BURN_H
|
||||||
|
|
||||||
|
@ -1,3 +1,4 @@
|
|||||||
|
/* vim: set sw=3 ts=3 sts=3 expandtab: */
|
||||||
#ifndef ECDB_COMMON_H
|
#ifndef ECDB_COMMON_H
|
||||||
#define ECDB_COMMON_H
|
#define ECDB_COMMON_H
|
||||||
|
|
||||||
|
@ -1,3 +1,4 @@
|
|||||||
|
/* vim: set sw=3 ts=3 sts=3 expandtab: */
|
||||||
#include "ecdb.h"
|
#include "ecdb.h"
|
||||||
|
|
||||||
void ecdb_drive_info_free_cb(void *data);
|
void ecdb_drive_info_free_cb(void *data);
|
||||||
|
@ -1,3 +1,4 @@
|
|||||||
|
/* vim: set sw=3 ts=3 sts=3 expandtab: */
|
||||||
#ifndef ECDB_DRIVES_H
|
#ifndef ECDB_DRIVES_H
|
||||||
#define ECDB_DRIVES_H
|
#define ECDB_DRIVES_H
|
||||||
|
|
||||||
|
@ -1,3 +1,4 @@
|
|||||||
|
/* vim: set sw=3 ts=3 sts=3 expandtab: */
|
||||||
#include "ecdb.h"
|
#include "ecdb.h"
|
||||||
|
|
||||||
int ecdb_erase_project_init(Ecdb_Erase_Project *proj);
|
int ecdb_erase_project_init(Ecdb_Erase_Project *proj);
|
||||||
|
@ -1,3 +1,4 @@
|
|||||||
|
/* vim: set sw=3 ts=3 sts=3 expandtab: */
|
||||||
#ifndef ECDB_ERASE_H
|
#ifndef ECDB_ERASE_H
|
||||||
#define ECDB_ERASE_H
|
#define ECDB_ERASE_H
|
||||||
|
|
||||||
|
@ -1,3 +1,4 @@
|
|||||||
|
/* vim: set sw=3 ts=3 sts=3 expandtab: */
|
||||||
#include "ecdb.h"
|
#include "ecdb.h"
|
||||||
|
|
||||||
static void free_file(Ewl_Filelist_File *file);
|
static void free_file(Ewl_Filelist_File *file);
|
||||||
|
@ -1,3 +1,4 @@
|
|||||||
|
/* vim: set sw=3 ts=3 sts=3 expandtab: */
|
||||||
#ifndef ECDB_FILELIST_CUSTOM_H
|
#ifndef ECDB_FILELIST_CUSTOM_H
|
||||||
#define ECDB_FILELIST_CUSTOM_H
|
#define ECDB_FILELIST_CUSTOM_H
|
||||||
|
|
||||||
|
@ -1,6 +1,4 @@
|
|||||||
/*
|
/* vim: set sw=3 ts=3 sts=3 expandtab: */
|
||||||
* vim:ts=3:sw=3:sts=3:expandtab
|
|
||||||
*/
|
|
||||||
#include "ecdb.h"
|
#include "ecdb.h"
|
||||||
|
|
||||||
static void ecdb_handle_typebuf(Evas_Object *gui);
|
static void ecdb_handle_typebuf(Evas_Object *gui);
|
||||||
@ -472,17 +470,34 @@ ecdb_cb_burn_image_page_buttons_clicked(void *data, Evas_Object *o,
|
|||||||
char buf[1024];
|
char buf[1024];
|
||||||
Ecdb_Burn_Result burn_result;
|
Ecdb_Burn_Result burn_result;
|
||||||
|
|
||||||
proj = ecdb_burn_project_new();
|
|
||||||
ecdb_project_type_set(ECDB_PROJECT(proj), ECDB_IMAGE_PROJECT);
|
|
||||||
entry = evas_object_name_find(ecore_evas_get(em->main_win_ee),
|
entry = evas_object_name_find(ecore_evas_get(em->main_win_ee),
|
||||||
"ecdb/burn_image/file");
|
"ecdb/burn_image/file");
|
||||||
file = edje_object_part_text_get(entry, "label");
|
file = edje_object_part_text_get(entry, "label");
|
||||||
|
|
||||||
//Textblock returns a <br> at the end, so chop that off
|
//Textblock returns a <br> at the end, so chop that off
|
||||||
|
if (!strcmp(&file[strlen(file) - 4], "<br>"))
|
||||||
|
{
|
||||||
sanitized_file = alloca(sizeof(char) * (strlen(file) - 3));
|
sanitized_file = alloca(sizeof(char) * (strlen(file) - 3));
|
||||||
sanitized_file[0] = '\0';
|
sanitized_file[0] = '\0';
|
||||||
ecore_strlcpy(sanitized_file, file, strlen(file) - 3);
|
ecore_strlcpy(sanitized_file, file, strlen(file) - 3);
|
||||||
|
printf("Sanitized_file: %s\n", sanitized_file);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
// We aren't altering sanitized_file after this
|
||||||
|
sanitized_file = (char *)file;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Make sure that file actually exists
|
||||||
|
if (!ecore_file_exists(sanitized_file))
|
||||||
|
{
|
||||||
|
edje_object_part_text_set(swallow, "progress_text", "File doesn't "
|
||||||
|
"exists!");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
proj = ecdb_burn_project_new();
|
||||||
|
ecdb_project_type_set(ECDB_PROJECT(proj), ECDB_IMAGE_PROJECT);
|
||||||
iso_file = ecdb_source_new();
|
iso_file = ecdb_source_new();
|
||||||
ecdb_source_data_set(iso_file, sanitized_file);
|
ecdb_source_data_set(iso_file, sanitized_file);
|
||||||
ecdb_source_child_append(proj->files, iso_file);
|
ecdb_source_child_append(proj->files, iso_file);
|
||||||
|
@ -1,3 +1,4 @@
|
|||||||
|
/* vim: set sw=3 ts=3 sts=3 expandtab: */
|
||||||
#ifndef ECDB_GUI_H
|
#ifndef ECDB_GUI_H
|
||||||
#define ECDB_GUI_H
|
#define ECDB_GUI_H
|
||||||
|
|
||||||
|
@ -1,3 +1,4 @@
|
|||||||
|
/* vim: set sw=3 ts=3 sts=3 expandtab: */
|
||||||
#include "ecdb.h"
|
#include "ecdb.h"
|
||||||
|
|
||||||
int ecdb_source_init(Ecdb_Source *src);
|
int ecdb_source_init(Ecdb_Source *src);
|
||||||
|
@ -1,3 +1,4 @@
|
|||||||
|
/* vim: set sw=3 ts=3 sts=3 expandtab: */
|
||||||
#ifndef ECDB_IMAGE_H
|
#ifndef ECDB_IMAGE_H
|
||||||
#define ECDB_IMAGE_H
|
#define ECDB_IMAGE_H
|
||||||
|
|
||||||
|
@ -1,3 +1,4 @@
|
|||||||
|
/* vim: set sw=3 ts=3 sts=3 expandtab: */
|
||||||
#include "ecdb.h"
|
#include "ecdb.h"
|
||||||
|
|
||||||
Ecdb_Project *
|
Ecdb_Project *
|
||||||
|
@ -1,3 +1,4 @@
|
|||||||
|
/* vim: set sw=3 ts=3 sts=3 expandtab: */
|
||||||
#ifndef ECDB_MISC_H
|
#ifndef ECDB_MISC_H
|
||||||
#define ECDB_MISC_H
|
#define ECDB_MISC_H
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user