more swigkey unification
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@8196 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
parent
33097285e4
commit
863961030d
9 changed files with 536 additions and 473 deletions
|
|
@ -11,6 +11,7 @@
|
|||
* ----------------------------------------------------------------------------- */
|
||||
|
||||
#include "swig.h"
|
||||
#include "swigkeys.h"
|
||||
#include <stdarg.h>
|
||||
#include <assert.h>
|
||||
|
||||
|
|
@ -304,16 +305,16 @@ Swig_require(const char *ns, Node *n, ...) {
|
|||
|
||||
/* Save the view */
|
||||
{
|
||||
String *view = Getattr(n,"view");
|
||||
String *view = Getattr(n,k_view);
|
||||
if (view) {
|
||||
if (Strcmp(view,ns) != 0) {
|
||||
strcpy(temp,ns);
|
||||
strcat(temp,":view");
|
||||
Setattr(n,temp,view);
|
||||
Setattr(n,"view",ns);
|
||||
Setattr(n,k_view,ns);
|
||||
}
|
||||
} else {
|
||||
Setattr(n,"view",ns);
|
||||
Setattr(n,k_view,ns);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -358,16 +359,16 @@ Swig_save(const char *ns, Node *n, ...) {
|
|||
|
||||
/* Save the view */
|
||||
{
|
||||
String *view = Getattr(n,"view");
|
||||
String *view = Getattr(n,k_view);
|
||||
if (view) {
|
||||
if (Strcmp(view,ns) != 0) {
|
||||
strcpy(temp,ns);
|
||||
strcat(temp,":view");
|
||||
Setattr(n,temp,view);
|
||||
Setattr(n,"view",ns);
|
||||
Setattr(n,k_view,ns);
|
||||
}
|
||||
} else {
|
||||
Setattr(n,"view",ns);
|
||||
Setattr(n,k_view,ns);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -387,7 +388,7 @@ Swig_restore(Node *n) {
|
|||
String *ns;
|
||||
Iterator ki;
|
||||
|
||||
ns = Getattr(n,"view");
|
||||
ns = Getattr(n,k_view);
|
||||
assert(ns);
|
||||
|
||||
l = NewList();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue