bool Interpolator::LinearQuaternion(FlKeyCode keycode, FlKeyGroup* g1, FlKeyGroup* g2, double t, Quaternion &qval) { qval = Quaternion(0, 0, 0, 1); if (!g1 || !g2) return false; FlKey *key1 = SearchKey(keycode, g1); FlKey *key2 = SearchKey(keycode, g2); if (!key1 || !key2) return false; if (key1->GetType()!=FLKEY_TYPE_QUATER || key2->GetType()!=FLKEY_TYPE_QUATER) return false; double t1, t2; Quaternion q1, q2; q1 = ((FlKeyQuaternion*)key1)->GetValue(); q2 = ((FlKeyQuaternion*)key2)->GetValue(); t1 = g1->t; t2 = g2->t; if (t1 == t2) { qval = q1; return true; } double st = Smooth((t-t1)/(t2-t1), g1->type==1, g2->type==1); qval = Slerp(q1, q2, st); return true; }
void BST < Filler > :: EliminaElemento ( NODO < Filler > * Nodo, Filler Key ){ if( this && Nodo ){ //RICERCA DELLA KEY if ( ( Nodo = SearchKey ( Nodo, Key ) ) ){ //CASO 1: NODO SENZA FIGLI if ( !Nodo->GetLeft () && !Nodo->GetRight () ){ ElimCasoUno( Nodo ); std :: cout << "Elemento Eliminato con successo" << std :: endl; } else{ //Almeno Uno if ( Nodo->GetLeft () && Nodo->GetRight () ){ //CASO 3: NODO CON DUE FIGLI ElimCasoTre ( Nodo ); } else{ //CASO 2: NODO CON UN FIGLIO ElimCasoDue( Nodo ); std :: cout << "Elemento Eliminato con successo" << std :: endl; } } } else { std :: cout << "Elemento NON TROVATO!" << std :: endl; } } else{ std :: cout << "L`Albero E`Vuoto!" << std :: endl; } }
float TFastIniSection::ReadFloat(AnsiString Key, float Default) { int index = SearchKey(Key); if (index >= 0){ return StrToFloatDef(Values(index), Default); }else{ return Default; } }
AnsiString TFastIniSection::ReadString(AnsiString Key, AnsiString Default) { int index = SearchKey(Key); if (index >= 0){ return Values(index); }else{ return Default; } }
int TFastIniSection::ReadInteger(AnsiString Key, int Default) { int index = SearchKey(Key); if (index >= 0){ return StrToIntDef(Values(index), Default); }else{ return Default; } }
LSQ_IteratorT LSQ_GetElementByIndex(LSQ_HandleT handle, LSQ_IntegerIndexT index){ if(NULL == handle) return NULL; TreePtr tree = handle; KeyPosPtr keyPos = SearchKey(tree->root, index); if(NULL == keyPos) return newTreeIterator(tree, NULL, 0, IT_BAD); TreeIteratorPtr it = newTreeIterator(tree, keyPos->node, keyPos->pos, IT_NORMAL); free(keyPos); return it; }
//interpolations bool Interpolator::StepDouble(FlKeyCode keycode, FlKeyGroup* g, double &dval) { dval = 0.0; if (!g) return false; FlKey *key = SearchKey(keycode, g); if (!key) return false; if (key->GetType()!=FLKEY_TYPE_DOUBLE) return false; dval = ((FlKeyDouble*)key)->GetValue(); return true; }
static float GetPathCost(const FRecastDebugPathfindingData& NodePool, const FNavigationProjectionWork& TestPt, const dtQueryFilter* Filter) { FRecastDebugPathfindingNode SearchKey(TestPt.OutLocation.NodeRef); const FRecastDebugPathfindingNode* MyNode = NodePool.Nodes.Find(SearchKey); if (MyNode) { return MyNode->TotalCost; } return BIG_NUMBER; }
bool Interpolator::StepQuaternion(FlKeyCode keycode, FlKeyGroup* g, Quaternion &qval) { qval = Quaternion(0, 0, 0, 1); if (!g) return false; FlKey *key = SearchKey(keycode, g); if (!key) return false; if (key->GetType()!=FLKEY_TYPE_QUATER) return false; qval = ((FlKeyQuaternion*)key)->GetValue(); return true; }
bool Interpolator::GetInt(FlKeyCode keycode, double t, int &ival) { int g1 = -1; int g2 = -1; for (int i=0; i<(int)m_key_list.size(); i++) { if (t > m_key_list[i]->t) g1 = i; else if (t < m_key_list[i]->t) { g2 = i; break; } else { g1 = g2 = i; break; } } if (g1 > -1) { FlKey *key = SearchKey(keycode, m_key_list[g1]); if (!key) return false; if (key->GetType() != FLKEY_TYPE_INT) return false; ival = ((FlKeyInt*)key)->GetValue(); return true; } else if (g2 > -1) { FlKey *key = SearchKey(keycode, m_key_list[g2]); if (!key) return false; if (key->GetType() != FLKEY_TYPE_INT) return false; ival = ((FlKeyInt*)key)->GetValue(); return true; } return false; }
static float GetPathLength(const FRecastDebugPathfindingData& NodePool, const FNavigationProjectionWork& TestPt, const dtQueryFilter* Filter) { FRecastDebugPathfindingNode SearchKey(TestPt.OutLocation.NodeRef); const FRecastDebugPathfindingNode* MyNode = NodePool.Nodes.Find(SearchKey); if (MyNode) { float LastSegmentLength = FVector::Dist(MyNode->NodePos, TestPt.OutLocation.Location); return MyNode->Length + LastSegmentLength; } return BIG_NUMBER; }
int LookupHashTable(HashTable table, HTKey_t key, HTKeyValue *keyvalue) { Verify333(table != NULL); // Step 2 -- implement LookupHashTable. // calculate which bucket we're searching in, // grab its linked list chain HWSize_t searchbucket = HashKeyToBucketNum(table, key); LinkedList searchchain = table->buckets[searchbucket]; return SearchKey(searchchain, key, keyvalue, 0) - 1; }
bool Interpolator::LinearDouble(FlKeyCode keycode, FlKeyGroup* g1, FlKeyGroup* g2, double t, double &dval) { dval = 0.0; if (!g1 || !g2) return false; FlKey *key1 = SearchKey(keycode, g1); FlKey *key2 = SearchKey(keycode, g2); if (!key1 || !key2) return false; if (key1->GetType()!=FLKEY_TYPE_DOUBLE || key2->GetType()!=FLKEY_TYPE_DOUBLE) return false; double v1, v2, t1, t2; v1 = ((FlKeyDouble*)key1)->GetValue(); v2 = ((FlKeyDouble*)key2)->GetValue(); t1 = g1->t; t2 = g2->t; if (t1 == t2) { dval = v1; return true; } double st = Smooth((t-t1)/(t2-t1), g1->type==1, g2->type==1); dval = v1 + st * (v2-v1); return true; }
int InsertHashTable(HashTable table, HTKeyValue newkeyvalue, HTKeyValue *oldkeyvalue) { HWSize_t insertbucket; LinkedList insertchain; Verify333(table != NULL); ResizeHashtable(table); // calculate which bucket we're inserting into, // grab its linked list chain insertbucket = HashKeyToBucketNum(table, newkeyvalue.key); insertchain = table->buckets[insertbucket]; // Step 1 -- finish the implementation of InsertHashTable. // This is a fairly complex task, so you might decide you want // to define/implement a helper function that helps you find // and optionally remove a key within a chain, rather than putting // all that logic inside here. You might also find that your helper // can be reused in steps 2 and 3. HTKeyValue *newnode = (HTKeyValue *) malloc(sizeof(HTKeyValue)); if (newnode == NULL) { // Error, out of memory. return 0; } *newnode = newkeyvalue; int searchresult = SearchKey(insertchain, newnode->key, oldkeyvalue, 1); if (searchresult != 0 && PushLinkedList(insertchain, newnode)) { // Successfully inserted. if (searchresult == 1) { // The key is not in the list yet. table->num_elements++; } // If the key has a duplication in the list, nothing to do, // since return value is searchresult = 2 // and "oldkeyvalue" is updated by SearchKey. return searchresult; } // Insertion failed. free(newnode); return 0; }
//get values at index bool Interpolator::GetDouble(FlKeyCode keycode, int index, double &dval) { if (index < 0 || index >= m_key_list.size()) { dval = 0.0; return false; } FlKey *key = SearchKey(keycode, m_key_list[index]); if (!key) { dval = 0.0; return false; } dval = ((FlKeyDouble*)key)->GetValue(); return true; }
bool Interpolator::GetBoolean(FlKeyCode keycode, int index, bool &bval) { if (index < 0 || index >= m_key_list.size()) { bval = false; return false; } FlKey *key = SearchKey(keycode, m_key_list[index]); if (!key) { bval = false; return false; } bval = ((FlKeyBoolean*)key)->GetValue(); return true; }
bool Interpolator::GetInt(FlKeyCode keycode, int index, int &ival) { if (index < 0 || index >= m_key_list.size()) { ival = 0; return false; } FlKey *key = SearchKey(keycode, m_key_list[index]); if (!key) { ival = 0; return false; } ival = ((FlKeyInt*)key)->GetValue(); return true; }
bool Interpolator::GetQuaternion(FlKeyCode keycode, int index, Quaternion &qval) { if (index < 0 || index >= m_key_list.size()) { qval = Quaternion(0, 0, 0, 1); return false; } FlKey *key = SearchKey(keycode, m_key_list[index]); if (!key) { qval = Quaternion(0, 0, 0, 1); return false; } qval = ((FlKeyQuaternion*)key)->GetValue(); return true; }
void GetPrivateProfileString (const char *section, const char *var, const char *def, char *get, int length, const char *filename) { char *buf; char *section_found; char *key_found; memset (get, 0, length); if (!filename) { strncpy (get, def, length); return; } buf = file2buf (filename); if (buf) { section_found = SearchSection (buf, section); if (section_found) { key_found = SearchKey (section_found, var); if (key_found) { char *val_start; char *val_end; val_start = strchr (key_found, '=') + 1; val_end = val_start; while ((*val_end != '\0') && (*val_end != '\n') && (*val_end != '\r')) val_end++; strncpy (get, val_start, val_end - val_start); get[val_end - val_start] = '\0'; return; } } } strncpy (get, def, length); }
bool AddKeyLoad(const CinematicKeyframe & key) { int num; if(!CKTrack || (key.frame < CKTrack->startframe) || (key.frame > CKTrack->endframe)) return false; CinematicKeyframe * k = SearchKey(key.frame, &num); if(!k) { if(!CKTrack->nbkey) { CKTrack->key = k = (CinematicKeyframe *)std::malloc(sizeof(CinematicKeyframe)); } else { CKTrack->key = (CinematicKeyframe *)std::realloc(CKTrack->key, sizeof(CinematicKeyframe) * (CKTrack->nbkey + 1)); k = SearchAndMoveKey(key.frame); } CKTrack->nbkey++; } *k = key; return true; }
int RemoveFromHashTable(HashTable table, HTKey_t key, HTKeyValue *keyvalue) { Verify333(table != NULL); // Step 3 -- implement RemoveFromHashTable. // calculate which bucket we're searching in, // grab its linked list chain HWSize_t searchbucket = HashKeyToBucketNum(table, key); LinkedList searchchain = table->buckets[searchbucket]; int searchresult = SearchKey(searchchain, key, keyvalue, 1); if (searchresult == 2) { // Key found. table->num_elements--; } // Key Not found, or error occurs (e.g., out of memory). return searchresult - 1; }
static bool HasPath(const FRecastDebugPathfindingData& NodePool, const NavNodeRef& NodeRef) { FRecastDebugPathfindingNode SearchKey(NodeRef); const FRecastDebugPathfindingNode* MyNode = NodePool.Nodes.Find(SearchKey); return MyNode != nullptr; }
static void UpDateKeyLight(int frame) { CinematicKeyframe *klightprev2, *klightnext2; int num; CinematicKeyframe * k = SearchKey(frame, &num); CinematicKeyframe * klightprev = k; CinematicKeyframe * klightnext = k; CinematicKeyframe * kbase = k; int num2 = num; //on cherche le range de deux lights //prev while(num2) { k--; if((k->fx & CinematicFxAllMask) == FX_LIGHT) { klightprev = k; break; } num2--; } //next k = kbase; num2 = num; while(num2 < (CKTrack->nbkey - 1)) { k++; if((k->fx & CinematicFxAllMask) == FX_LIGHT) { klightnext = k; break; } num2++; } //on crépie le range avec ces deux valeurs kbase->light.prev = klightprev; kbase->light.next = klightnext; if((kbase->fx & CinematicFxAllMask) == FX_LIGHT) { klightprev2 = klightnext2 = kbase; } else { kbase->light.intensity = -1.f; klightprev2 = klightprev; klightnext2 = klightnext; } //prev k = kbase - 1; while(k >= CKTrack->key) { if(klightprev == kbase) { k->light.intensity = -1.f; } k->light.next = klightnext2; if((k->fx & CinematicFxAllMask) == FX_LIGHT) break; k->light.prev = klightprev; k--; } //next k = kbase + 1; while(k < (CKTrack->key + CKTrack->nbkey)) { if(klightnext == kbase) { k->light.intensity = -1.f; } k->light.prev = klightprev2; if((k->fx & CinematicFxAllMask) == FX_LIGHT) break; k->light.next = klightnext; k++; } }
bool AddKey(const CinematicKeyframe & key) { int num; if(!CKTrack || (key.frame < CKTrack->startframe) || (key.frame > CKTrack->endframe)) return false; CinematicKeyframe * k = SearchKey(key.frame, &num); if(!k) { if(!CKTrack->nbkey) { CKTrack->key = k = (CinematicKeyframe *)std::malloc(sizeof(CinematicKeyframe)); } else { CKTrack->key = (CinematicKeyframe *)std::realloc(CKTrack->key, sizeof(CinematicKeyframe) * (CKTrack->nbkey + 1)); k = SearchAndMoveKey(key.frame); } CKTrack->nbkey++; k->frame = key.frame; } if(key.numbitmap > -2) k->numbitmap = key.numbitmap; if(key.fx > -2) { k->fx = key.fx; /* TODO what was this code suppesed to achieve if((key.fx > 255) && (k->fx > 0)) { k->fx |= key.fx; } else { if((k->fx >= 255) && (key.fx >= 0)) { k->fx |= key.fx; } else { k->fx = key.fx; } } */ } if(key.speed > -1.f) { k->speed = key.speed; } k->color = key.color; k->colord = key.colord; k->colorf = key.colorf; if(key.idsound > -2) { k->idsound = key.idsound; } if(key.force > -2) k->force = key.force; k->frame = key.frame; k->pos = key.pos; k->angz = key.angz; if(key.typeinterp > -2) k->typeinterp = key.typeinterp; float a = -2.f; if(C_NEQUAL_F32(key.light.intensity, a)) { k->light = key.light; } k->posgrille = key.posgrille; k->angzgrille = key.angzgrille; k->speedtrack = key.speedtrack; UpDateAllKeyLight(); return true; }
static bool HasPath(const FRecastDebugPathfindingData& NodePool, const FNavigationProjectionWork& TestPt) { FRecastDebugPathfindingNode SearchKey(TestPt.OutLocation.NodeRef); const FRecastDebugPathfindingNode* MyNode = NodePool.Nodes.Find(SearchKey); return MyNode != nullptr; }
void WritePrivateProfileString (const char *section, const char *var, const char *var_name, const char *filename) { FILE *file; struct stat sb; int res; res = stat (filename, &sb); if (-1 == res) // fichier n'existe pas { file = fopen (filename, "w"); InsertSectionKey (section, var, var_name, file, 0); fclose (file); } else { int filesize; filesize = sb.st_size - 1; // on ne lit pas EOT if (filesize >= 0) { char *buf; char *section_begin; int size1, size2; buf = file2buf (filename); section_begin = SearchSection (buf, section); if (NULL != section_begin) //section existe déjà { char *key_begin; key_begin = SearchKey (section_begin, var); if (NULL != key_begin) // la clé existe : on copie la partie d'avant l'ancienne clé, la nouvelle clé, puis la partie d'après l'ancienne clé { int old_key_size; char *key_end; size1 = key_begin - buf; key_end = strstr (key_begin, "\n"); if (NULL != key_end) { old_key_size = key_end - key_begin + 1; size2 = filesize - (size1 + old_key_size); file = fopen (filename, "w"); fwrite (buf, size1, 1, file); WriteKey (var, var_name, file); fwrite (buf + size1 + old_key_size, size2, 1, file); fclose (file); } else { // la clé est la dernière du fichier file = fopen (filename, "w"); fwrite (buf, size1, 1, file); WriteKey (var, var_name, file); fclose (file); } } else { // clé n'existe pas : on la rajoute avant la prochaine section char *next_section_begin; next_section_begin = strstr (section_begin, "*"); if (NULL == next_section_begin) // la section recherchée est unique : il suffit de copier la clé à la fin du fichier { file = fopen (filename, "a"); WriteKey (var, var_name, file); fclose (file); } else { // on insère la clé avant la prochaine section size1 = next_section_begin - buf; size2 = filesize - size1; file = fopen (filename, "w"); fwrite (buf, size1, 1, file); WriteKey (var, var_name, file); fwrite (buf + size1, size2, 1, file); fclose (file); } } } else { //section n'existe pas : on la rajoute ainsi que la clé file = fopen (filename, "a"); InsertSectionKey (section, var, var_name, file, 1); fclose (file); } free (buf); } else { //taille fichier < 0 file = fopen (filename, "w"); InsertSectionKey (section, var, var_name, file, 0); fclose (file); } } }
QString MenuCommands::Get(int ind, What w) const { int cur = 0; if (cur++ == ind) return (w == Key ? FileKey() : (w == Title? FileTitle() : "")); if (cur++ == ind) return (w == Key ? NewWinKey() : (w == Title? NewWinTitle() : GetStr(NewWinShortcuts()))); if (cur++ == ind) return (w == Key ? OpenFileKey() : (w == Title? OpenFileTitle() : GetStr(OpenFileShortcuts()))); if (cur++ == ind) return (w == Key ? OpenLocKey() : (w == Title? OpenLocTitle() : GetStr(OpenLocShortcuts()))); if (cur++ == ind) return (w == Key ? SaveAsKey() : (w == Title? SaveAsTitle() : GetStr(SaveAsShortcuts()))); if (cur++ == ind) return (w == Key ? SavePdfKey() : (w == Title? SavePdfTitle() : GetStr(SavePdfShortcuts()))); if (cur++ == ind) return (w == Key ? ImportKey() : (w == Title? ImportTitle() : "")); if (cur++ == ind) return (w == Key ? ImportIEKey() : (w == Title? ImportIETitle() : GetStr(ImportIEShortcuts()))); if (cur++ == ind) return (w == Key ? ImportFFKey() : (w == Title? ImportFFTitle() : GetStr(ImportFFShortcuts()))); if (cur++ == ind) return (w == Key ? ImportHtmlKey() : (w == Title? ImportHtmlTitle() : GetStr(ImportHtmlShortcuts()))); if (cur++ == ind) return (w == Key ? ImportXmlKey() : (w == Title? ImportXmlTitle() : GetStr(ImportXmlShortcuts()))); if (cur++ == ind) return (w == Key ? ExportKey() : (w == Title? ExportTitle() : GetStr(ExportShortcuts()))); if (cur++ == ind) return (w == Key ? PrintKey() : (w == Title? PrintTitle() : GetStr(PrintShortcuts()))); if (cur++ == ind) return (w == Key ? PreviewKey() : (w == Title? PreviewTitle() : GetStr(PreviewShortcuts()))); if (cur++ == ind) return (w == Key ? QuitKey() : (w == Title? QuitTitle() : GetStr(QuitShortcuts()))); if (cur++ == ind) return (w == Key ? EditKey() : (w == Title? EditTitle() : "")); if (cur++ == ind) return (w == Key ? UndoKey() : (w == Title? UndoTitle() : GetStr(UndoShortcuts()))); if (cur++ == ind) return (w == Key ? RedoKey() : (w == Title? RedoTitle() : GetStr(RedoShortcuts()))); if (cur++ == ind) return (w == Key ? CutKey() : (w == Title? CutTitle() : GetStr(CutShortcuts()))); if (cur++ == ind) return (w == Key ? CopyKey() : (w == Title? CopyTitle() : GetStr(CopyShortcuts()))); if (cur++ == ind) return (w == Key ? PasteKey() : (w == Title? PasteTitle() : GetStr(PasteShortcuts()))); if (cur++ == ind) return (w == Key ? FindKey() : (w == Title? FindTitle() : GetStr(FindShortcuts()))); if (cur++ == ind) return (w == Key ? NextKey() : (w == Title? NextTitle() : GetStr(NextShortcuts()))); if (cur++ == ind) return (w == Key ? PrevKey() : (w == Title? PrevTitle() : GetStr(PrevShortcuts()))); if (cur++ == ind) return (w == Key ? PrefsKey() : (w == Title? PrefsTitle() : GetStr(PrefsShortcuts()))); if (cur++ == ind) return (w == Key ? ViewKey() : (w == Title? ViewTitle() : "")); if (cur++ == ind) return (w == Key ? AppStylesKey() : (w == Title? AppStylesTitle() : "")); if (cur++ == ind) return (w == Key ? StatusKey() : (w == Title? StatusTitle() : GetStr(StatusShortcuts()))); if (cur++ == ind) return (w == Key ? MenuKey() : (w == Title? MenuTitle() : GetStr(MenuShortcuts()))); if (cur++ == ind) return (w == Key ? TabKey() : (w == Title? TabTitle() : GetStr(TabShortcuts()))); if (cur++ == ind) return (w == Key ? NavKey() : (w == Title? NavTitle() : GetStr(NavShortcuts()))); if (cur++ == ind) return (w == Key ? BooksKey() : (w == Title? BooksTitle() : GetStr(BooksShortcuts()))); // if (cur++ == ind) // return (w == Key ? Key() : (w == Title? Title() : GetStr(Shortcuts()))); if (cur++ == ind) return (w == Key ? StopKey() : (w == Title? StopTitle() : GetStr(StopShortcuts()))); if (cur++ == ind) return (w == Key ? ReloadKey() : (w == Title? ReloadTitle() : GetStr(ReloadShortcuts()))); if (cur++ == ind) return (w == Key ? LargerKey() : (w == Title? LargerTitle() : GetStr(LargerShortcuts()))); if (cur++ == ind) return (w == Key ? NormalKey() : (w == Title? NormalTitle() : GetStr(NormalShortcuts()))); if (cur++ == ind) return (w == Key ? SmallerKey() : (w == Title? SmallerTitle() : GetStr(SmallerShortcuts()))); if (cur++ == ind) return (w == Key ? TextOnlyKey() : (w == Title? TextOnlyTitle() : GetStr(TextOnlyShortcuts()))); if (cur++ == ind) return (w == Key ? EncodeKey() : (w == Title? EncodeTitle() : "")); if (cur++ == ind) return (w == Key ? SourceKey() : (w == Title? SourceTitle() : GetStr(SourceShortcuts()))); if (cur++ == ind) return (w == Key ? FullKey() : (w == Title? FullTitle() : GetStr(FullShortcuts()))); if (cur++ == ind) return (w == Key ? HistoryKey() : (w == Title? HistoryTitle() : "")); if (cur++ == ind) return (w == Key ? BackKey() : (w == Title? BackTitle() : GetStr(BackShortcuts()))); if (cur++ == ind) return (w == Key ? ForwKey() : (w == Title? ForwTitle() : GetStr(ForwShortcuts()))); if (cur++ == ind) return (w == Key ? HomeKey() : (w == Title? HomeTitle() : GetStr(HomeShortcuts()))); if (cur++ == ind) return (w == Key ? LastTabKey() : (w == Title? LastTabTitle() : GetStr(LastTabShortcuts()))); if (cur++ == ind) return (w == Key ? LastTabsKey() : (w == Title? LastTabsTitle() : GetStr(LastTabsShortcuts()))); if (cur++ == ind) return (w == Key ? SessionKey() : (w == Title? SessionTitle() : GetStr(SessionShortcuts()))); if (cur++ == ind) return (w == Key ? AllHistKey() : (w == Title? AllHistTitle() : GetStr(AllHistShortcuts()))); if (cur++ == ind) return (w == Key ? ClearKey() : (w == Title? ClearTitle() : GetStr(ClearShortcuts()))); if (cur++ == ind) return (w == Key ? BookmarksKey() : (w == Title? BookmarksTitle() : "")); if (cur++ == ind) return (w == Key ? AllBooksKey() : (w == Title? AllBooksTitle() : GetStr(AllBooksShortcuts()))); if (cur++ == ind) return (w == Key ? AddBookKey() : (w == Title? AddBookTitle() : GetStr(AddBookShortcuts()))); if (cur++ == ind) return (w == Key ? PrivacyKey() : (w == Title? PrivacyTitle() : "")); if (cur++ == ind) return (w == Key ? PrivateKey() : (w == Title? PrivateTitle() : GetStr(PrivateShortcuts()))); if (cur++ == ind) return (w == Key ? JavaScriptKey() : (w == Title? JavaScriptTitle() : GetStr(JavaScriptShortcuts()))); if (cur++ == ind) return (w == Key ? ImagesKey() : (w == Title? ImagesTitle() : GetStr(ImagesShortcuts()))); if (cur++ == ind) return (w == Key ? CookiesKey() : (w == Title? CookiesTitle() : GetStr(CookiesShortcuts()))); if (cur++ == ind) return (w == Key ? PlugInsKey() : (w == Title? PlugInsTitle() : GetStr(PlugInsShortcuts()))); if (cur++ == ind) return (w == Key ? AgentKey() : (w == Title? AgentTitle() : GetStr(AgentShortcuts()))); if (cur++ == ind) return (w == Key ? PopUpsKey() : (w == Title? PopUpsTitle() : GetStr(PopUpsShortcuts()))); if (cur++ == ind) return (w == Key ? ProxyKey() : (w == Title? ProxyTitle() : GetStr(ProxyShortcuts()))); if (cur++ == ind) return (w == Key ? EmptyKey() : (w == Title? EmptyTitle() : GetStr(EmptyShortcuts()))); if (cur++ == ind) return (w == Key ? ResetKey() : (w == Title? ResetTitle() : GetStr(ResetShortcuts()))); if (cur++ == ind) return (w == Key ? FullResetKey() : (w == Title? FullResetTitle() : GetStr(FullResetShortcuts()))); if (cur++ == ind) return (w == Key ? ToolsKey() : (w == Title? ToolsTitle() : "")); if (cur++ == ind) return (w == Key ? CompatKey() : (w == Title? CompatTitle() : "")); if (cur++ == ind) return (w == Key ? SearchKey() : (w == Title? SearchTitle() : GetStr(SearchShortcuts()))); if (cur++ == ind) return (w == Key ? KeyboardKey() : (w == Title? KeyboardTitle() : GetStr(KeyboardShortcuts()))); if (cur++ == ind) return (w == Key ? InspectorKey() : (w == Title? InspectorTitle() : GetStr(InspectorShortcuts()))); if (cur++ == ind) return (w == Key ? InspectKey() : (w == Title? InspectTitle() : GetStr(InspectShortcuts()))); if (cur++ == ind) return (w == Key ? OptionsKey() : (w == Title? OptionsTitle() : GetStr(OptionsShortcuts()))); if (cur++ == ind) return (w == Key ? WindowKey() : (w == Title? WindowTitle() : "")); if (cur++ == ind) return (w == Key ? NextTabKey() : (w == Title? NextTabTitle() : GetStr(NextTabShortcuts()))); if (cur++ == ind) return (w == Key ? PrevTabKey() : (w == Title? PrevTabTitle() : GetStr(PrevTabShortcuts()))); if (cur++ == ind) return (w == Key ? NewTabKey() : (w == Title? NewTabTitle() : GetStr(NewTabShortcuts()))); if (cur++ == ind) return (w == Key ? CloseTabKey() : (w == Title? CloseTabTitle() : GetStr(CloseTabShortcuts()))); if (cur++ == ind) return (w == Key ? CloseOtherKey() : (w == Title? CloseOtherTitle() : GetStr(CloseOtherShortcuts()))); if (cur++ == ind) return (w == Key ? CloneTabKey() : (w == Title? CloneTabTitle() : GetStr(CloneTabShortcuts()))); if (cur++ == ind) return (w == Key ? ReloadTabKey() : (w == Title? ReloadTabTitle() : GetStr(ReloadTabShortcuts()))); if (cur++ == ind) return (w == Key ? ReloadAllKey() : (w == Title? ReloadAllTitle() : GetStr(ReloadAllShortcuts()))); if (cur++ == ind) return (w == Key ? OpenNewTabKey() : (w == Title? OpenNewTabTitle() : GetStr(OpenNewTabShortcuts()))); if (cur++ == ind) return (w == Key ? OpenAdBlockKey() : (w == Title? OpenAdBlockTitle() : GetStr(OpenAdBlockShortcuts()))); if (cur++ == ind) return (w == Key ? SwapFocusKey() : (w == Title? SwapFocusTitle() : GetStr(SwapFocusShortcuts()))); if (cur++ == ind) return (w == Key ? CopyAddrKey() : (w == Title? CopyAddrTitle() : "")); if (cur++ == ind) return (w == Key ? DownsKey() : (w == Title? DownsTitle() : GetStr(DownsShortcuts()))); if (cur++ == ind) return (w == Key ? TorrentsKey() : (w == Title? TorrentsTitle() : GetStr(TorrentsShortcuts()))); if (cur++ == ind) return (w == Key ? HelpKey() : (w == Title? HelpTitle() : GetStr(HelpShortcuts()))); if (cur++ == ind) return (w == Key ? OnlineKey() : (w == Title? OnlineTitle() : GetStr(OnlineShortcuts()))); if (cur++ == ind) return (w == Key ? UpdatesKey() : (w == Title? UpdatesTitle() : GetStr(UpdatesShortcuts()))); if (cur++ == ind) return (w == Key ? AboutKey() : (w == Title? AboutTitle() : GetStr(AboutShortcuts()))); return ""; }