Enlightenment CVS committal
Author : davemds
Project : e17
Module : proto/edje_editor
Dir : e17/proto/edje_editor/src/bin
Modified Files:
edje_editor_consolle.h edje_editor_dialogs.c
edje_editor_part.c edje_editor_toolbar.c edje_editor_tree.c
edje_editor_window.c inout.c inout.h main.c main.h
Log Message:
* finish renaming & cleaning !!!!
===================================================================
RCS file: /cvs/e/e17/proto/edje_editor/src/bin/edje_editor_consolle.h,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -3 -r1.2 -r1.3
--- edje_editor_consolle.h 2 Jul 2008 02:48:58 -0000 1.2
+++ edje_editor_consolle.h 2 Jul 2008 17:54:31 -0000 1.3
@@ -2,7 +2,9 @@
#define _EDJE_EDITOR_CONSOLLE_H_
-Evas_Object *EV_Consolle; //The lower consolle panel
+Evas_Object *EV_Consolle; //The lower consolle panel
+Evas_List *stack; //Stack for the consolle
+int consolle_count; //Counter for the consolle
===================================================================
RCS file: /cvs/e/e17/proto/edje_editor/src/bin/edje_editor_dialogs.c,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -3 -r1.5 -r1.6
--- edje_editor_dialogs.c 2 Jul 2008 16:31:19 -0000 1.5
+++ edje_editor_dialogs.c 2 Jul 2008 17:54:31 -0000 1.6
@@ -87,7 +87,7 @@
snprintf(cmd,4096,"%s/%s",
etk_filechooser_widget_current_folder_get(ETK_FILECHOOSER_WIDGET(UI_FileChooser)),
etk_filechooser_widget_selected_file_get(ETK_FILECHOOSER_WIDGET(UI_FileChooser)));
- LoadEDJ(cmd);
+ load_edje(cmd);
break;
case FILECHOOSER_SAVE_EDJ:
printf("SAVE EDJ\n");
===================================================================
RCS file: /cvs/e/e17/proto/edje_editor/src/bin/edje_editor_part.c,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -3 -r1.7 -r1.8
--- edje_editor_part.c 2 Jul 2008 17:27:02 -0000 1.7
+++ edje_editor_part.c 2 Jul 2008 17:54:31 -0000 1.8
@@ -275,7 +275,7 @@
else
edje_edit_part_source_set(edje_o, Cur.part->string, NULL);
- ReloadEdje();
+ reload_edje();
return ETK_TRUE;
}
===================================================================
RCS file: /cvs/e/e17/proto/edje_editor/src/bin/edje_editor_toolbar.c,v
retrieving revision 1.8
retrieving revision 1.9
diff -u -3 -r1.8 -r1.9
--- edje_editor_toolbar.c 2 Jul 2008 17:27:02 -0000 1.8
+++ edje_editor_toolbar.c 2 Jul 2008 17:54:31 -0000 1.9
@@ -317,7 +317,8 @@
button = etk_tool_button_new_from_stock(ETK_STOCK_DOCUMENT_PROPERTIES);
etk_toolbar_append(ETK_TOOLBAR(UI_Toolbar), button, ETK_BOX_START);
etk_signal_connect("clicked", ETK_OBJECT(button),
- ETK_CALLBACK(on_AllButton_click),
(void*)TOOLBAR_DEBUG);
+ ETK_CALLBACK(_window_all_button_click_cb),
+ (void*)TOOLBAR_DEBUG);
etk_object_properties_set(ETK_OBJECT(button),"label","Debug",NULL);
#endif
===================================================================
RCS file: /cvs/e/e17/proto/edje_editor/src/bin/edje_editor_tree.c,v
retrieving revision 1.12
retrieving revision 1.13
diff -u -3 -r1.12 -r1.13
--- edje_editor_tree.c 2 Jul 2008 17:27:02 -0000 1.12
+++ edje_editor_tree.c 2 Jul 2008 17:54:31 -0000 1.13
@@ -356,7 +356,7 @@
char *gr;
gr = etk_combobox_item_field_get(item,0);
//printf("Group combo activated: %s\n",gr);
- ChangeGroup(gr);
+ change_group(gr);
return ETK_TRUE;
}
===================================================================
RCS file: /cvs/e/e17/proto/edje_editor/src/bin/edje_editor_window.c,v
retrieving revision 1.16
retrieving revision 1.17
diff -u -3 -r1.16 -r1.17
--- edje_editor_window.c 2 Jul 2008 17:27:02 -0000 1.16
+++ edje_editor_window.c 2 Jul 2008 17:54:31 -0000 1.17
@@ -376,7 +376,7 @@
etk_tree_row_select(row);
//Reload the edje if needed
if (edje_edit_part_type_get(edje_o, Cur.part->string) ==
EDJE_PART_TYPE_GROUP)
- ReloadEdje();
+ reload_edje();
break;
case TOOLBAR_MOVE_DOWN: //Raise
@@ -398,7 +398,7 @@
etk_tree_row_select(row);
//Reload the edje if needed
if (edje_edit_part_type_get(edje_o, Cur.part->string) ==
EDJE_PART_TYPE_GROUP)
- ReloadEdje();
+ reload_edje();
break;
case IMAGE_BROWSER_SHOW:
image_browser_show(1);
@@ -482,7 +482,7 @@
toolbar_play_button_toggle(-1);
break;
case TOOLBAR_DEBUG:
- //DebugInfo(FALSE);
+ //print_debug_info(FALSE);
//ChangeGroup("New group");
//edje_edit_group_add(edje_o, "dai cazzo");
//on_AddMenu_item_activated(NULL, NEW_RECT);
===================================================================
RCS file: /cvs/e/e17/proto/edje_editor/src/bin/inout.c,v
retrieving revision 1.9
retrieving revision 1.10
diff -u -3 -r1.9 -r1.10
--- inout.c 15 Feb 2008 21:41:21 -0000 1.9
+++ inout.c 2 Jul 2008 17:54:31 -0000 1.10
@@ -116,20 +116,20 @@
//~ etk_widget_show_all(Save_Win);
//~ }
-int
-backup_file(char *file_name)
-{
- char bkname[4096];
- if (!ecore_file_exists(file_name))
- return 0;
+//~ int
+//~ backup_file(char *file_name)
+//~ {
+ //~ char bkname[4096];
+ //~ if (!ecore_file_exists(file_name))
+ //~ return 0;
- snprintf(bkname,4095,"%s.bkp",file_name);
+ //~ snprintf(bkname,4095,"%s.bkp",file_name);
- if (ecore_file_cp(file_name,bkname))
- return TRUE;
- else
- return FALSE;
-}
+ //~ if (ecore_file_cp(file_name,bkname))
+ //~ return TRUE;
+ //~ else
+ //~ return FALSE;
+//~ }
//~ char*
//~ SaveEDC(char *file_name)
===================================================================
RCS file: /cvs/e/e17/proto/edje_editor/src/bin/inout.h,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -3 -r1.5 -r1.6
--- inout.h 15 Feb 2008 21:41:21 -0000 1.5
+++ inout.h 2 Jul 2008 17:54:31 -0000 1.6
@@ -1,10 +1,10 @@
#include "main.h"
-//void LoadEDJ (char *file);
-int SaveEDJ (char *file_name);
-char* SaveEDC (char *file_name);
-int Decompile (void *data); //data is the name of the file to open
-int pipe_data (void *data, int ev_type, void *ev);
-int load_pipe_exit (void *data, int ev_type, void *ev);
-int save_pipe_exit (void *data, int ev_type, void *ev);
-void stop_bar (Etk_Widget *pbar, char *text);
+//~ void LoadEDJ (char *file);
+//~ int SaveEDJ (char *file_name);
+//~ char* SaveEDC (char *file_name);
+//~ int Decompile (void *data); //data is the name of the file to open
+//~ int pipe_data (void *data, int ev_type, void *ev);
+//~ int load_pipe_exit (void *data, int ev_type, void *ev);
+//~ int save_pipe_exit (void *data, int ev_type, void *ev);
+//~ void stop_bar (Etk_Widget *pbar, char *text);
===================================================================
RCS file: /cvs/e/e17/proto/edje_editor/src/bin/main.c,v
retrieving revision 1.53
retrieving revision 1.54
diff -u -3 -r1.53 -r1.54
--- main.c 2 Jul 2008 17:27:02 -0000 1.53
+++ main.c 2 Jul 2008 17:54:31 -0000 1.54
@@ -1,4 +1,3 @@
-#include "config.h"
#include <string.h>
#include <errno.h>
#include <locale.h>
@@ -6,66 +5,25 @@
#include <Edje_Edit.h>
#include <Etk.h>
#include <Ecore_Str.h>
-
+#include "config.h"
#include "main.h"
Evas_Object *EdjeTest_bg;
Evas_Object *EdjeTest_edje;
+/*** Test MiniApp ***/
void
-on_test_win_resize(Ecore_Evas * ee)
-{
- int w, h;
-
- evas_output_size_get(ecore_evas_get(ee), &w, &h);
- printf("RESIZE: %d - %d\n", w,h);
-
- //evas_object_move(preview, barwidth, 0);
- evas_object_resize(EdjeTest_bg, w , h );
- evas_object_resize(EdjeTest_edje, w , h );
-}
-
-Evas_Bool
-_DebugInfo_helper(Evas_Hash *hash, const char *key, void *data, void *fdata)
+_test_win_resize_cb(Ecore_Evas * ee)
{
- printf("Key: '%s' [%d]\n", key, (int)data);
- return TRUE;
-}
+ int w, h;
-void
-DebugInfo(int full)
-{
- printf("\n\n ********************* D E B U G
***************************\n");
- printf(" ** open file name: %s\n",Cur.edj_file_name->string);
- printf(" ** temp file name: %s\n",Cur.edj_temp_name->string);
- printf(" ** edje_editor.edj: %s\n",EdjeFile);
- if (etk_string_length_get(Cur.group))
- printf(" ** Cur group: %s\n",Cur.group->string);
- else
- printf(" ** Cur group: (NULL)\n");
- if (etk_string_length_get(Cur.part))
- printf(" ** Cur part: %s\n",Cur.part->string);
- else
- printf(" ** Cur part: (NULL)\n");
- if (etk_string_length_get(Cur.state))
- printf(" ** Cur state: %s\n",Cur.state->string);
- else
- printf(" ** Cur state: (NULL)\n");
- if (etk_string_length_get(Cur.prog))
- printf(" ** Cur program: %s\n",Cur.prog->string);
- else
- printf(" ** Cur program: (NULL)\n");
- if (etk_string_length_get(Cur.tween))
- printf(" ** Cur tween: %s\n",Cur.tween->string);
- else
- printf(" ** Cur tween: (NULL)\n");
- printf(" *********************** Parts_Hash
*****************************\n");
- evas_hash_foreach(Parts_Hash, _DebugInfo_helper, NULL);
- printf(" *********************** E N D *****************************\n\n");
+ evas_output_size_get(ecore_evas_get(ee), &w, &h);
+ evas_object_resize(EdjeTest_bg, w , h );
+ evas_object_resize(EdjeTest_edje, w , h );
}
void
-TestEdjeGroup(char *File,char *Group)
+test_edje_group(char *File,char *Group)
{
Ecore_Evas *ee;
Evas *evas;
@@ -77,7 +35,7 @@
ecore_evas_init();
ee = ecore_evas_software_x11_new(NULL, 0, 0, 0, 0, 0);
ecore_evas_title_set(ee, "Edje Test Application");
- ecore_evas_callback_resize_set(ee, on_test_win_resize);
+ ecore_evas_callback_resize_set(ee, _test_win_resize_cb);
edje_init();
evas = ecore_evas_get(ee);
@@ -110,8 +68,50 @@
ecore_main_loop_begin();
}
+
+/*** Debug Info ***/
+Evas_Bool
+_debug_info_helper(Evas_Hash *hash, const char *key, void *data, void *fdata)
+{
+ printf("Key: '%s' [%d]\n", key, (int)data);
+ return TRUE;
+}
+
+void
+print_debug_info(int full)
+{
+ printf("\n\n ********************* D E B U G
***************************\n");
+ printf(" ** open file name: %s\n",Cur.edj_file_name->string);
+ printf(" ** temp file name: %s\n",Cur.edj_temp_name->string);
+ printf(" ** edje_editor.edj: %s\n",EdjeFile);
+ if (etk_string_length_get(Cur.group))
+ printf(" ** Cur group: %s\n",Cur.group->string);
+ else
+ printf(" ** Cur group: (NULL)\n");
+ if (etk_string_length_get(Cur.part))
+ printf(" ** Cur part: %s\n",Cur.part->string);
+ else
+ printf(" ** Cur part: (NULL)\n");
+ if (etk_string_length_get(Cur.state))
+ printf(" ** Cur state: %s\n",Cur.state->string);
+ else
+ printf(" ** Cur state: (NULL)\n");
+ if (etk_string_length_get(Cur.prog))
+ printf(" ** Cur program: %s\n",Cur.prog->string);
+ else
+ printf(" ** Cur program: (NULL)\n");
+ if (etk_string_length_get(Cur.tween))
+ printf(" ** Cur tween: %s\n",Cur.tween->string);
+ else
+ printf(" ** Cur tween: (NULL)\n");
+ printf(" *********************** Parts_Hash
*****************************\n");
+ evas_hash_foreach(Parts_Hash, _debug_info_helper, NULL);
+ printf(" *********************** E N D *****************************\n\n");
+}
+
+/*** Implementation ***/
void
-PrintUsage(void)
+print_usage(void)
{
printf("\nUsage:\n");
printf(" edje_editor [EDC | EDJ] [IMAGE_DIR] [FONT_DIR]\n");
@@ -127,7 +127,7 @@
}
void
-ChangeGroup(char *group)
+change_group(char *group)
{
if (!group) return;
@@ -174,7 +174,8 @@
}
-void ReloadEdje(void)
+void
+reload_edje(void)
{
if (!etk_string_length_get(Cur.group)) return;
if (!etk_string_length_get(Cur.edj_temp_name)) return;
@@ -184,11 +185,10 @@
edje_edit_save(edje_o);
edje_object_file_set(edje_o, EdjeFile, "IMAGE.PNG");
edje_object_file_set(edje_o, Cur.edj_temp_name->string, Cur.group->string);
-
}
int
-LoadEDJ(char *file)
+load_edje(char *file)
{
unsigned char new_file = 0;
char *realp = NULL;
@@ -302,7 +302,7 @@
(0 == strcmp(argv[1],"--help")) ||
(0 == strcmp(argv[1],"--usage")) )
{
- PrintUsage();
+ print_usage();
return 1;
}
}
@@ -312,10 +312,10 @@
{
if (argc < 4)
{
- PrintUsage();
+ print_usage();
return 1;
}
- TestEdjeGroup(argv[2],argv[3]);
+ test_edje_group(argv[2],argv[3]);
return 0;
}
@@ -355,15 +355,15 @@
if (argc == 2)
{
printf("Opening edje file: '%s'\n",argv[1]);
- LoadEDJ(argv[1]);
+ load_edje(argv[1]);
}
else
//Open blank.edj
{
- LoadEDJ(NULL);
+ load_edje(NULL);
}
- //DebugInfo(FALSE);
+ //print_debug_info(FALSE);
//Show main window
ecore_evas_show(UI_ecore_MainWin);
===================================================================
RCS file: /cvs/e/e17/proto/edje_editor/src/bin/main.h,v
retrieving revision 1.40
retrieving revision 1.41
diff -u -3 -r1.40 -r1.41
--- main.h 2 Jul 2008 02:48:58 -0000 1.40
+++ main.h 2 Jul 2008 17:54:31 -0000 1.41
@@ -22,10 +22,10 @@
#include "edje_editor_window.h"
/* DEFINES */
-#define FAKEWIN_BORDER_TOP 16
-#define FAKEWIN_BORDER_LEFT 7
-#define FAKEWIN_BORDER_RIGHT 4
-#define FAKEWIN_BORDER_BOTTOM 4
+//#define FAKEWIN_BORDER_TOP 16
+//#define FAKEWIN_BORDER_LEFT 7
+//#define FAKEWIN_BORDER_RIGHT 4
+//#define FAKEWIN_BORDER_BOTTOM 4
#define USE_GL_ENGINE 0
#define DEBUG_MODE 0
@@ -36,19 +36,6 @@
#define TREE_WIDTH 265
#endif
-#undef FREE
-#define FREE(val) \
-{ \
- free(val); val = NULL; \
-}
-
-#undef IF_FREE
-#define IF_FREE(val) \
-{ \
- if (val) FREE(val) \
- val = NULL; \
-}
-
//All the enum used are declared here
enum various
{
@@ -147,7 +134,7 @@
Etk_String *edj_file_name;
Etk_String *edj_temp_name;
- int fullscreen; //The current main window state
+ int fullscreen; //The current main window state
}Cur;
/* GLOBALS */
@@ -158,15 +145,11 @@
Evas_Hash *Parts_Hash; //Associate part names with
Etk_Tree_Row*
-
-Evas_List *stack; //Stack for the consolle
-int consolle_count; //Counter for the consolle
-
/* FUNCTION PROTOTYPES*/
-void DebugInfo(int full);
-int LoadEDJ(char *file);
-void ChangeGroup(char *group);
-void ReloadEdje(void);
+void print_debug_info (int full);
+void change_group (char *group);
+int load_edje (char *file);
+void reload_edje (void);
//This define is copied from edje_private.h (find a way to export it)
@@ -215,4 +198,4 @@
#define EDJE_ASPECT_PREFER_HORIZONTAL 2
#define EDJE_ASPECT_PREFER_BOTH 3
-#endif // INCLUSION_GUARD
+#endif
-------------------------------------------------------------------------
Sponsored by: SourceForge.net Community Choice Awards: VOTE NOW!
Studies have shown that voting for your favorite open source project,
along with a healthy diet, reduces your potential for chronic lameness
and boredom. Vote Now at http://www.sourceforge.net/community/cca08
_______________________________________________
enlightenment-cvs mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs