FieldFindData * fieldFind = &findData[c]; \
SQLiteField sqlFld = (SQLiteField)findData->field; \
Class dataType = sqlFld.type; \
- BindData(stmt, bindId++, sqlFld, (dataType.type == structClass || dataType.type == noHeadClass || dataType.type == normalClass) ? fieldFind->value.p : &fieldFind->value.i, null); \
+ BindData(stmt, bindId++, sqlFld, (dataType.type == structClass || dataType.type == noHeadClass || dataType.type == normalClass) ? fieldFind->value.p : &fieldFind->value.i64, null); \
}
if(numFields)
borderStyle = deep;
public:
- uint filter;
+ Id filter;
bool filtered;
Field nameField;
- uint exclusion;
+ Id exclusion;
Table table;
Field filterField;
- property uint filter
+ property Id filter
{
set
{
get { return filter; }
}
property Field nameField { set { nameField = value; } }
- property uint exclusion { set { exclusion = value; } }
+ property Id exclusion { set { exclusion = value; } }
property Table table { set { table = value; if(!nameField && value) nameField = value.FindField(defaultNameField); } }
virtual void Refill()
public:
- property uint filter { set { filtered = true; filter = value; } get { return filter; } }
+ property Id filter { set { filtered = true; filter = value; } get { return filter; } }
property bool filtered { set { filtered = value; } }
- property uint exclusion { set { exclusion = value; } }
+ property Id exclusion { set { exclusion = value; } }
property Field filterField { set { filterField = value; } }
property Field nameField { set { nameField = value; } }
virtual void TableDropBox::RefillFunction();
if(editor)
{
TableDropBox dropBox = (TableDropBox) editor;
- uint id = data ? *(uint *)data : MAXDWORD;
+ Id id = data ? *(Id *)data : MAXDWORD;
void * notifyChanged = (void *)NotifyChanged;
OnConfigure(dropBox);
private:
Field nameField;
Field filterField;
- uint exclusion;
- uint filter;
+ Id exclusion;
+ Id filter;
bool filtered;
bool showNone;
}
showNone = true;
public:
- property uint filter { set { filtered = true; filter = value; } get { return filter; } }
+ property Id filter { set { filtered = true; filter = value; } get { return filter; } }
property bool filtered { set { filtered = value; } }
- property uint exclusion { set { exclusion = value; } }
+ property Id exclusion { set { exclusion = value; } }
property Field filterField { set { filterField = value; } }
property Field nameField { set { nameField = value; } }
virtual void TableDropBox::RefillFunction();
if(editor)
{
TableDropBox dropBox = (TableDropBox) editor;
- uint id = data ? *(uint *)data : MAXDWORD;
+ Id id = data ? *(Id *)data : MAXDWORD;
OnConfigure(dropBox);
dropBox.Refill();
if(id != MAXDWORD) dropBox.SelectRow(dropBox.FindSubRow(id));
private:
Field nameField;
Field filterField;
- uint exclusion;
- uint filter;
+ Id exclusion;
+ Id filter;
bool filtered;
bool showNone;
}
list.NotifySelect(this, list, null, 0);
if(!editor.modifiedDocument)
{
- uint id; // = table.rowsCount + 1; // this is bad with deleted rows, won't work, how to have unique id?
+ Id id; // = table.rowsCount + 1; // this is bad with deleted rows, won't work, how to have unique id?
Row r { table };
if(r.Last()) // this will reuse ids in cases where the item(s) with the last id have been deleted
}
};
- virtual void Window::NotifySelectListRow(ListSection listSection, uint64 id);
+ virtual void Window::NotifySelectListRow(ListSection listSection, Id id);
void SelectListRow(DataRow row)
{
// Time startTime = GetTime();
if(row)
{
- uint64 id = row.tag;
+ Id id = row.tag;
lastRow = row;
if(list.currentRow != row)
{
Row row { f.lookupFindIndex ? f.lookupFindIndex : f.lookupFindField.table };
// todo: make this work for all types
- uint id = 0;
+ Id id = 0;
editRow.GetData(f.lookupValueField, id);
// TODO: add alternative class instance for creation when no rows are found via lookup
for(row.Find(f.lookupFindField, middle, nil, id); !row.nil; row.Next())
{
// todo: make this work for all types, although this is meant to be an id field
- uint id = 0;
+ Id id = 0;
TableEditor editor = eInstance_New(f.editorClass);
incref editor;
editor.parent = f.parentWindow;
//list.NotifySelect(this, list, null, 0);
if(table && editRow && editRow.tbl && !modifiedDocument)
{
- uint id; // = table.rowsCount + 1; // this is bad with deleted rows, won't work, how to have unique id?
+ Id id; // = table.rowsCount + 1; // this is bad with deleted rows, won't work, how to have unique id?
// I think the 3 following comment lines apply to the old sqlite driver before many fix we done for wsms
Row r = editRow;// { table }; // the multipurpose row is buggy with sqlite driver, you can't use the same row to do Row::Last(), Row::Next(), Row::Find(), etc...
//Row r { editRow.tbl }; // for example, Row::Last() here is not using the proper sqlite statement and fails to
void OnSerialize(IOChannel channel)
{
WordEntry node;
- uint id;
+ Id id;
DebugLn("WordEntryBinaryTree::OnSerialize");
for(id = 1, node = (WordEntry)root; node;)
{
IdList items;
IdList words;
- uint id;
+ Id id;
~WordEntry()
{
channel.Serialize(words.count);
for(c = 0; c < words.count; c++)
{
- uint id = (uint)((WordEntry)(uintptr)words.ids[c]).id;
+ Id id = (Id)((WordEntry)(uintptr)words.ids[c]).id;
channel.Serialize(id);
}
}
}
else
{
- uint nothing = 0;
+ Id nothing = 0;
channel.Serialize(nothing);
}
#endif
void OnUnserialize(IOChannel channel)
{
#ifdef FULL_STRING_SEARCH
- uint id;
+ Id id;
channel.Unserialize(id);
if(id)
{
bool DataBox::NotifySelect(DropBox control, DataRow row, Modifiers mods)
{
- // TOFIX: Id is still 32 bit
- uint id = (uint)(row ? row.tag : 0);
+ Id id = (Id)(row ? row.tag : 0);
SetData(&id, mods.closingDropDown);
return true;
}
dropBox.Create();
dropBox.currentRow = dropBox.FindSubRow(this);
if(!dropBox.currentRow && this)
- dataBox.SetData((uint *)&this, false);
+ dataBox.SetData((Id *)&this, false);
{
DataRow r = dropBox.currentRow;
if(r)
}
else
{
- uint id = this;
+ Id id = this;
id.OnGetString(tempString, null, null);
}
}
int c;
for(c = 0; c<count; c++)
{
- uint64 idA = ids[c], idB = b.ids[c];
+ Id idA = ids[c], idB = b.ids[c];
if(idA > idB) return 1;
else if(idA < idB) return -1;
}
// if(type.type != normalClass || strcmp(type.dataTypeString, "char *"))
if(type)
{
- void * data = ((type.type == normalClass || type.type == noHeadClass || type.type == structClass) ? row.GetData(null) : (void *)(uintptr)*(uint *)row.GetData(null));
+ void * data = ((type.type == normalClass || type.type == noHeadClass || type.type == structClass) ? row.GetData(null) : (void *)(uintptr)*(Id *)row.GetData(null));
if(!data)
{
//if(strcmp(type.dataTypeString, char *"))