DLL_EXPORT int NotifyEvent(void *client, char *entry_point, int Sender, char *EventData, int len) {
    CConceptClient *CC = (CConceptClient *)client;
    if ((CC) && (CC->parser)) {
        AnsiString temp;
        if (len > 0)
            temp.LoadBuffer(EventData, len);
        CC->parser->NotifyEvent(entry_point, Sender, temp);
        return 1;
    }
    return 0;
}
Exemplo n.º 2
0
//---------------------------------------------------------------------------
AnsiString CONCEPT_TO_STRING(JSContext *cx, void *member) {
    INTEGER    type     = 0;
    char       *szValue = 0;
    NUMBER     nValue   = 0;
    AnsiString ret;

    InvokePtr(INVOKE_GET_VARIABLE, member, &type, &szValue, &nValue);
    switch (type) {
        case VARIABLE_NUMBER:
            ret = AnsiString(nValue);
            break;

        case VARIABLE_STRING:
            ret.LoadBuffer(szValue, (int)nValue);
            break;

        default:
            ret = "1";
    }
    return ret;
}