Changeset 47


Ignore:
Timestamp:
Mar 13, 2001, 1:20:46 PM (24 years ago)
Author:
umoeller
Message:

misc changes

Location:
trunk/src/helpers
Files:
7 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/helpers/cctl_tooltip.c

    r29 r47  
    967967             *          of the window that contains the area, and the "rect" member must
    968968             *          specify the client coordinates of the area's bounding
    969              *          rectangle. ### not implemented yet
     969             *          rectangle.
    970970             *
    971971             *      --  When you add a tool implemented as a window, the "hwndTool"
     
    988988             *
    989989             *      To retrieve the text for a tool, use the TTM_GETTEXT message.
     990             *
     991             *@@todo: add tool rectangles
    990992             */
    991993
     
    12861288             *      Additional note: On input, if TOOLINFO.lpszText == PSZ_TEXTCALLBACK,
    12871289             *      this sends the TTN_NEEDTEXT notification to TOOLINFO.hwnd.
     1290             *
     1291             *@@todo add TTFMT_STRINGRES
    12881292             */
    12891293
     
    13181322
    13191323                        case TTFMT_STRINGRES:
    1320                             // ### not supported yet
     1324
    13211325                        break;
    13221326                    }
  • trunk/src/helpers/configsys.c

    r24 r47  
    983983                    if (pszDeletedLine)
    984984                    {
    985                         // did we delete a line?  ###
     985                        // did we delete a part?
    986986                        xstrcat(pstrChanged, "DLP ", 0);
    987987                        xstrcat(pstrChanged, pManip->pszNewLine, 0);
  • trunk/src/helpers/linklist.c

    r38 r47  
    1515 *      <B>Usage:</B>
    1616 *
     17 *      Linked lists are implemented through the LINKLIST structure.
     18 *      This can either be created on the stack or as a global variable
     19 *      (and must then be initialized using lstInit) or from the heap
     20 *      with lstCreate.
     21 *
    1722 *      Each list item is stored in a LISTNODE structure, which in
    1823 *      turn has a pItemData field, which you can use to get your
    19  *      data. So a typical list would be coded like this:
    20  *
     24 *      data. So a typical list would be coded like this (this is
     25 *      a heap list):
     26 *
     27 +
     28 +          typedef struct _YOURDATA
     29 +          {
     30 +              ULONG ulWhatever;
     31 +          } YOURDATA, *PYOURDATA
     32 +
    2133 +          // fill the list
    2234 +          PLINKLIST pll = lstCreate(TRUE or FALSE);
    2335 +          while ...
    2436 +          {
    25  +              PYOURDATA pYourData = ...
     37 +              PYOURDATA pYourData = (PYOURDATA)malloc(sizeof(YOURDATA));
    2638 +              lstAppendItem(pll, pYourData);  // store the data in a new node
    2739 +          }
     
    5668
    5769/*
    58  *      Copyright (C) 1997-2000 Ulrich M”ller.
     70 *      Copyright (C) 1997-2001 Ulrich M”ller.
    5971 *      This file is part of the "XWorkplace helpers" source package.
    6072 *      This is free software; you can redistribute it and/or modify
     
    120132/*
    121133 *@@ lstInit:
    122  *      this initializes a given linked list.
     134 *      this initializes a given LINKLIST structure.
     135 *
    123136 *      This is useful only if you have a static
    124  *      LINKLIST structure in your sources and don't
    125  *      use lstCreate/lstFree to have lists created
    126  *      dynamically. In that case, use this function
    127  *      as follows:
     137 *      LINKLIST structure in your sources (either as
     138 *      a global variable or as a stack variable) and
     139 *      don't use lstCreate/lstFree to have lists created
     140 *      from the heap.
     141 *
     142 *      In that case, use this function as follows:
    128143 +
    129144 +          LINKLIST llWhatever;
     
    138153 *      invoked on list items automatically in lstClear,
    139154 *      lstRemoveNode, and lstRemoveItem.
    140  *      Set this to TRUE if you have created the
    141  *      list items yourself. Set this to FALSE if
    142  *      you're storing other objects, such as numbers
    143  *      or other static items.
    144  *
    145  *      This of course will be a "flat" free(). If
    146  *      you store structures in the list using other
    147  *      heap pointers, auto-free would cause memory leaks.
    148  *
    149  *      Also, auto-free only works if the malloc() that
    150  *      has been used on the list item is in the same C
    151  *      runtime as with the linklist functions. If the
    152  *      caller uses a different runtime (e.g. from a DLL),
    153  *      it can use lstMalloc() for allocating the list
    154  *      item and still use auto-free.
     155 *
     156 *      --  Set this to TRUE if you have created the
     157 *          list items yourself using malloc().
     158 *
     159 *          This of course will be a "flat" free(). If
     160 *          you store structures in the list using other
     161 *          heap pointers, auto-free would cause memory leaks.
     162 *
     163 *          Also, auto-free only works if the malloc() that
     164 *          has been used on the list item is in the same C
     165 *          runtime as with the linklist functions. If the
     166 *          caller uses a different runtime (e.g. from a DLL),
     167 *          it  can use lstMalloc() for allocating the list
     168 *          item and still use auto-free.
     169 *
     170 *      --  Set this to FALSE if you're storing other
     171 *          objects, such as numbers or other static items.
    155172 *
    156173 *      Note: You better call lstInit only once per list,
     
    185202 *      when the list was initialized (lstInit), free()
    186203 *      will be invoked on all data item pointers also.
    187  *      See the remarks there.
     204 *      See the remarks for lstInit.
    188205 *
    189206 *      Returns FALSE only upon errors, e.g. because
     
    259276 *      using lstFree.
    260277 *
    261  *      If (fItemsFreeable == TRUE), free() will be
    262  *      invoked on list items automatically in lstFree,
    263  *      lstRemoveNode, and lstRemoveItem.
    264  *      Set this to TRUE if you have created the
    265  *      list items yourself. Set this to FALSE if
    266  *      you're storing other objects, such as numbers
    267  *      or other static items.
     278 *      See lstInit for the description of fItemsFreeable.
    268279 *
    269280 *      Returns NULL upon errors.
     
    298309 *      when the list was created (lstCreate), free()
    299310 *      will be invoked on all data item pointers also.
    300  *      See the remarks there.
    301  *
    302  *      This must only be used with dynamic lists created
     311 *      See the remarks for lstInit.
     312 *
     313 *      This must only be used with heap lists created
    303314 *      with lstCreate.
    304315 */
  • trunk/src/helpers/textview.c

    r25 r47  
    810810        {
    811811            // four characters with hex anchor index (>=1)
    812             // or ####
     812            // or "####"
    813813            if (  *( (*ppCurrent)+2 )
    814814                  == '#'
     
    10711071 *
    10721072 *@@changed V0.9.3 (2000-05-06) [umoeller]: largely rewritten; now handling paragraph and character formats
     1073 *@@todo TXVWORDF_GLUEWITHNEXT
    10731074 */
    10741075
  • trunk/src/helpers/tmsgfile.c

    r21 r47  
    292292        {
    293293            // create a temporary buffer for replacements
    294             PSZ             pszTemp = (PSZ)malloc(cbBuffer); // ### memory leak here!
     294            PSZ             pszTemp = (PSZ)malloc(cbBuffer);
    295295
    296296            if (!pszTemp)
     
    373373
    374374                ulBytesRead = ulTargetWritten;
    375             }
     375
     376                free(pszTemp);      // V0.9.9 (2001-03-13) [umoeller]
     377            } // if pszTemp
    376378        }                           // end if (cTable)
    377379
     
    478480 *@@changed V0.9.1 (99-12-12) [umoeller]: file last-write date is now reset when EAs are written
    479481 *@@changed V0.9.1 (2000-02-01) [umoeller]: now skipping leading spaces in msg
     482 *@@todo handle 64KB EA limit
    480483 */
    481484
     
    766769
    767770        // write new timestamp and table
    768         // ### handle 64 kb limit here !!!
     771        // @@todo handle 64 kb limit here !!!
    769772        if (rc == NO_ERROR)
    770773        {
  • trunk/src/helpers/winh.c

    r46 r47  
    28732873 *@@changed V0.9.7 (2000-12-17) [umoeller]: PROGDETAILS.pszEnvironment no longer zeroed
    28742874 *@@changed V0.9.9 (2001-01-27) [umoeller]: crashed if PROGDETAILS.pszExecutable was NULL
     2875 *@@todo PROG_DEFAULT ain't working; test winhQueryAppType
    28752876 */
    28762877
     
    29182919            case ((ULONG)-1):       // we get that sometimes...
    29192920            case PROG_DEFAULT:
    2920                 // ###
     2921                // @@todo
    29212922            break;
    29222923        }
  • trunk/src/helpers/xml.c

    r39 r47  
    18481848 *      @expat handler for @notation_declarations.
    18491849 *
    1850  *      ###
     1850 *      @@todo
    18511851 *
    18521852 *@@added V0.9.9 (2001-02-14) [umoeller]
     
    19501950 *
    19511951 *      It is the application's responsibility to free this data
    1952  *      structure. ###
     1952 *      structure. @@todo
    19531953 *
    19541954 *      The XML spec defines that no element may be declared more
Note: See TracChangeset for help on using the changeset viewer.