Revision: 51302
          
http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=51302
Author:   mont29
Date:     2012-10-13 15:44:50 +0000 (Sat, 13 Oct 2012)
Log Message:
-----------
More UI messages fixes.
Also forgot to translate reports' titles, and change some usages of BKE_reportf 
to simple BKE_report, when the former is not needed!

Modified Paths:
--------------
    trunk/blender/source/blender/blenkernel/intern/anim.c
    trunk/blender/source/blender/blenkernel/intern/packedFile.c
    trunk/blender/source/blender/blenkernel/intern/report.c
    trunk/blender/source/blender/blenloader/intern/readfile.c
    trunk/blender/source/blender/blenloader/intern/writefile.c
    trunk/blender/source/blender/editors/interface/interface_ops.c
    trunk/blender/source/blender/makesrna/intern/rna_animation_api.c
    trunk/blender/source/blender/makesrna/intern/rna_nodetree.c
    trunk/blender/source/blender/makesrna/intern/rna_object_api.c
    trunk/blender/source/blender/makesrna/intern/rna_wm.c
    trunk/blender/source/blender/quicktime/apple/quicktime_export.c
    trunk/blender/source/blender/windowmanager/intern/wm_init_exit.c
    trunk/blender/source/blender/windowmanager/intern/wm_operators.c

Modified: trunk/blender/source/blender/blenkernel/intern/anim.c
===================================================================
--- trunk/blender/source/blender/blenkernel/intern/anim.c       2012-10-13 
13:55:14 UTC (rev 51301)
+++ trunk/blender/source/blender/blenkernel/intern/anim.c       2012-10-13 
15:44:50 UTC (rev 51302)
@@ -40,6 +40,8 @@
 #include "BLI_rand.h"
 #include "BLI_utildefines.h"
 
+#include "BLF_translation.h"
+
 #include "DNA_anim_types.h"
 #include "DNA_armature_types.h"
 #include "DNA_group_types.h"
@@ -174,10 +176,10 @@
        /* avoid 0 size allocs */
        if (avs->path_sf >= avs->path_ef) {
                BKE_reportf(reports, RPT_ERROR,
-                           "Motion Path frame extents invalid for %s (%d to 
%d).%s\n",
+                           "Motion Path frame extents invalid for %s (%d to 
%d)%s",
                            (pchan) ? pchan->name : ob->id.name,
                            avs->path_sf, avs->path_ef,
-                           (avs->path_sf == avs->path_ef) ? " Cannot have 
single-frame paths." : "");
+                           (avs->path_sf == avs->path_ef) ? TIP_(", cannot 
have single-frame paths") : "");
                return NULL;
        }
 

Modified: trunk/blender/source/blender/blenkernel/intern/packedFile.c
===================================================================
--- trunk/blender/source/blender/blenkernel/intern/packedFile.c 2012-10-13 
13:55:14 UTC (rev 51301)
+++ trunk/blender/source/blender/blenkernel/intern/packedFile.c 2012-10-13 
15:44:50 UTC (rev 51302)
@@ -238,7 +238,8 @@
                                ima->packedfile = newPackedFile(reports, 
ima->name, ID_BLEND_PATH(bmain, &ima->id));
                        }
                        else if (ELEM(ima->source, IMA_SRC_SEQUENCE, 
IMA_SRC_MOVIE)) {
-                               BKE_reportf(reports, RPT_WARNING, "Image '%s' 
skipped, movies and image sequences not supported.", ima->id.name + 2);
+                               BKE_reportf(reports, RPT_WARNING, "Image '%s' 
skipped, movies and image sequences not supported",
+                                           ima->id.name + 2);
                        }
                }
        }

Modified: trunk/blender/source/blender/blenkernel/intern/report.c
===================================================================
--- trunk/blender/source/blender/blenkernel/intern/report.c     2012-10-13 
13:55:14 UTC (rev 51301)
+++ trunk/blender/source/blender/blenkernel/intern/report.c     2012-10-13 
15:44:50 UTC (rev 51302)
@@ -46,15 +46,24 @@
 static const char *report_type_str(int type)
 {
        switch (type) {
-               case RPT_DEBUG: return "Debug";
-               case RPT_INFO: return "Info";
-               case RPT_OPERATOR: return "Operator";
-               case RPT_WARNING: return "Warning";
-               case RPT_ERROR: return "Error";
-               case RPT_ERROR_INVALID_INPUT: return "Invalid Input Error";
-               case RPT_ERROR_INVALID_CONTEXT: return "Invalid Context Error";
-               case RPT_ERROR_OUT_OF_MEMORY: return "Out Of Memory Error";
-               default: return "Undefined Type";
+               case RPT_DEBUG:
+                       return TIP_("Debug");
+               case RPT_INFO:
+                       return TIP_("Info");
+               case RPT_OPERATOR:
+                       return TIP_("Operator");
+               case RPT_WARNING:
+                       return TIP_("Warning");
+               case RPT_ERROR:
+                       return TIP_("Error");
+               case RPT_ERROR_INVALID_INPUT:
+                       return TIP_("Invalid Input Error");
+               case RPT_ERROR_INVALID_CONTEXT:
+                       return TIP_("Invalid Context Error");
+               case RPT_ERROR_OUT_OF_MEMORY:
+                       return TIP_("Out Of Memory Error");
+               default:
+                       return TIP_("Undefined Type");
        }
 }
 

Modified: trunk/blender/source/blender/blenloader/intern/readfile.c
===================================================================
--- trunk/blender/source/blender/blenloader/intern/readfile.c   2012-10-13 
13:55:14 UTC (rev 51301)
+++ trunk/blender/source/blender/blenloader/intern/readfile.c   2012-10-13 
15:44:50 UTC (rev 51302)
@@ -6611,7 +6611,7 @@
                G.main = main;
                
                if (!(do_version_tface(main, 1))) {
-                       BKE_report(fd->reports, RPT_WARNING, "Texface 
conversion problem. Error in console");
+                       BKE_report(fd->reports, RPT_WARNING, "Texface 
conversion problem (error in console)");
                }
                
                //XXX hack, material.c uses G.main allover the place, instead 
of main

Modified: trunk/blender/source/blender/blenloader/intern/writefile.c
===================================================================
--- trunk/blender/source/blender/blenloader/intern/writefile.c  2012-10-13 
13:55:14 UTC (rev 51301)
+++ trunk/blender/source/blender/blenloader/intern/writefile.c  2012-10-13 
15:44:50 UTC (rev 51302)
@@ -3022,7 +3022,7 @@
 
        file = BLI_open(tempname, O_BINARY+O_WRONLY+O_CREAT+O_TRUNC, 0666);
        if (file == -1) {
-               BKE_reportf(reports, RPT_ERROR, "Can't open file %s for 
writing: %s.", tempname, strerror(errno));
+               BKE_reportf(reports, RPT_ERROR, "Can't open file %s for 
writing: %s", tempname, strerror(errno));
                return 0;
        }
 
@@ -3073,7 +3073,7 @@
        if (write_flags & G_FILE_HISTORY) { 
                int err_hist = do_history(filepath, reports);
                if (err_hist) {
-                       BKE_report(reports, RPT_ERROR, "Version backup failed. 
File saved with @");
+                       BKE_report(reports, RPT_ERROR, "Version backup failed 
(file saved with @)");
                        return 0;
                }
        }
@@ -3090,23 +3090,23 @@
                if (0==ret) {
                        /* now rename to real file name, and delete temp @ file 
too */
                        if (BLI_rename(gzname, filepath) != 0) {
-                               BKE_report(reports, RPT_ERROR, "Can't change 
old file. File saved with @.");
+                               BKE_report(reports, RPT_ERROR, "Can't change 
old file (file saved with @)");
                                return 0;
                        }
 
                        BLI_delete(tempname, 0, 0);
                }
                else if (-1==ret) {
-                       BKE_report(reports, RPT_ERROR, "Failed opening .gz 
file.");
+                       BKE_report(reports, RPT_ERROR, "Failed opening .gz 
file");
                        return 0;
                }
                else if (-2==ret) {
-                       BKE_report(reports, RPT_ERROR, "Failed opening .blend 
file for compression.");
+                       BKE_report(reports, RPT_ERROR, "Failed opening .blend 
file for compression");
                        return 0;
                }
        }
        else if (BLI_rename(tempname, filepath) != 0) {
-               BKE_report(reports, RPT_ERROR, "Can't change old file. File 
saved with @");
+               BKE_report(reports, RPT_ERROR, "Can't change old file (file 
saved with @)");
                return 0;
        }
 

Modified: trunk/blender/source/blender/editors/interface/interface_ops.c
===================================================================
--- trunk/blender/source/blender/editors/interface/interface_ops.c      
2012-10-13 13:55:14 UTC (rev 51301)
+++ trunk/blender/source/blender/editors/interface/interface_ops.c      
2012-10-13 15:44:50 UTC (rev 51302)
@@ -808,7 +808,7 @@
 
        if (text == NULL) {
                BKE_reportf(op->reports, RPT_WARNING,
-                           "file: '%s' can't be opened", filepath);
+                           "File: '%s' can't be opened", filepath);
                return OPERATOR_CANCELLED;
        }
        else {

Modified: trunk/blender/source/blender/makesrna/intern/rna_animation_api.c
===================================================================
--- trunk/blender/source/blender/makesrna/intern/rna_animation_api.c    
2012-10-13 13:55:14 UTC (rev 51301)
+++ trunk/blender/source/blender/makesrna/intern/rna_animation_api.c    
2012-10-13 15:44:50 UTC (rev 51302)
@@ -60,7 +60,7 @@
                                break;
                                
                        case MODIFYKEY_MISSING_TYPEINFO:
-                               BKE_report(reports, RPT_ERROR, "Incomplete 
built-in Keying Set. Appears to be missing type info");
+                               BKE_report(reports, RPT_ERROR, "Incomplete 
built-in Keying Set, appears to be missing type info");
                                break;
                }
        }

Modified: trunk/blender/source/blender/makesrna/intern/rna_nodetree.c
===================================================================
--- trunk/blender/source/blender/makesrna/intern/rna_nodetree.c 2012-10-13 
13:55:14 UTC (rev 51301)
+++ trunk/blender/source/blender/makesrna/intern/rna_nodetree.c 2012-10-13 
15:44:50 UTC (rev 51302)
@@ -689,7 +689,7 @@
        bNodeTemplate ntemp;
 
        if (type == NODE_GROUP && group == NULL) {
-               BKE_reportf(reports, RPT_ERROR, "node type \'GROUP\' missing 
group argument");
+               BKE_report(reports, RPT_ERROR, "Node type 'GROUP' missing group 
argument");
                return NULL;
        }
        
@@ -700,7 +700,7 @@
        node = nodeAddNode(ntree, &ntemp);
        
        if (node == NULL) {
-               BKE_reportf(reports, RPT_ERROR, "Unable to create node");
+               BKE_report(reports, RPT_ERROR, "Unable to create node");
        }
        else {
                ntreeUpdateTree(ntree); /* update group node socket links*/
@@ -800,7 +800,7 @@
        nodeFindNode(ntree, tosock, &tonode, NULL, &to_in_out);
        
        if (&from_in_out == &to_in_out) {
-               BKE_reportf(reports, RPT_ERROR, "Same input/output direction of 
sockets");
+               BKE_report(reports, RPT_ERROR, "Same input/output direction of 
sockets");
                return NULL;
        }
 
@@ -827,7 +827,7 @@
 static void rna_NodeTree_link_remove(bNodeTree *ntree, ReportList *reports, 
bNodeLink *link)
 {
        if (BLI_findindex(&ntree->links, link) == -1) {
-               BKE_reportf(reports, RPT_ERROR, "Unable to locate link in node 
tree");
+               BKE_report(reports, RPT_ERROR, "Unable to locate link in node 
tree");
        }
        else {
                nodeRemLink(ntree, link);
@@ -882,9 +882,9 @@
        int index, in_out;
        
        if (!nodeFindNode(ntree, sock, &node, &index, &in_out))
-               BKE_reportf(reports, RPT_ERROR, "Unable to locate socket in 
node tree");
+               BKE_report(reports, RPT_ERROR, "Unable to locate socket in node 
tree");
        else if (in_out != SOCK_IN)
-               BKE_reportf(reports, RPT_ERROR, "Socket is not an input");
+               BKE_report(reports, RPT_ERROR, "Socket is not an input");
        else {
                /* XXX should check if tree is a group here! no good way to do 
this currently. */
                gsock = node_group_add_socket(ntree, sock->name, sock->type, 
SOCK_IN);
@@ -906,9 +906,9 @@
        int index, in_out;
        
        if (!nodeFindNode(ntree, sock, &node, &index, &in_out))
-               BKE_reportf(reports, RPT_ERROR, "Unable to locate socket in 
node tree");
+               BKE_report(reports, RPT_ERROR, "Unable to locate socket in node 
tree");
        else if (in_out != SOCK_OUT)
-               BKE_reportf(reports, RPT_ERROR, "Socket is not an output");
+               BKE_report(reports, RPT_ERROR, "Socket is not an output");
        else {
                /* XXX should check if tree is a group here! no good way to do 
this currently. */
                gsock = node_group_add_socket(ntree, sock->name, sock->type, 
SOCK_OUT);

Modified: trunk/blender/source/blender/makesrna/intern/rna_object_api.c
===================================================================
--- trunk/blender/source/blender/makesrna/intern/rna_object_api.c       
2012-10-13 13:55:14 UTC (rev 51301)
+++ trunk/blender/source/blender/makesrna/intern/rna_object_api.c       
2012-10-13 15:44:50 UTC (rev 51302)
@@ -158,7 +158,7 @@
                        /* BKE_mesh_from_nurbs changes the type to a mesh, 
check it worked */
                        if (tmpobj->type != OB_MESH) {
                                BKE_libblock_free_us(&(G.main->object), tmpobj);
-                               BKE_report(reports, RPT_ERROR, "cant convert 
curve to mesh. Does the curve have any segments?");

@@ Diff output truncated at 10240 characters. @@
_______________________________________________
Bf-blender-cvs mailing list
[email protected]
http://lists.blender.org/mailman/listinfo/bf-blender-cvs

Reply via email to