Changeset 1546 for trunk/dll


Ignore:
Timestamp:
Oct 24, 2010, 12:33:00 AM (15 years ago)
Author:
Gregg Young
Message:

Add menu item to allow opening of directory container from the collector based on the path of the selected item. (Ticket 362) Add open file button to EAs dialog to allow opening of a new file's eas (Ticket 439). Initial work on populating the help table (It provides F1 help a few more places) (Ticket 95). Some minor code cleanup and help file updates.

Location:
trunk/dll
Files:
15 edited

Legend:

Unmodified
Added
Removed
  • trunk/dll/avl.c

    r1544 r1546  
    3838  11 Jan 08 GKY Replace "ARCHIVER.BB2" in string file with global set at compile in init.c
    3939  08 Mar 09 GKY Additional strings move to PCSZs in init.c
     40  23 Oct 10 GKY Changes to populate and utilize a HELPTABLE for context specific help
    4041
    4142***********************************************************************/
     
    810811
    811812    break;
     813
     814  case WM_HELP:
     815      if (hwndHelp)
     816        WinSendMsg(hwndHelp,
     817                   HM_DISPLAY_HELP,
     818                   MPFROMSHORT(1), MPFROMSHORT(HM_RESOURCEID));
     819      break;
    812820
    813821  case WM_COMMAND:
  • trunk/dll/cmdline.c

    r1544 r1546  
    2828  21 Dec 09 GKY Added CheckExecutibleFlags to streamline code in command.c assoc.c & cmdline.c
    2929  17 JAN 10 GKY Changes to get working with Watcom 1.9 Beta (1/16/10). Mostly cast CHAR CONSTANT * as CHAR *.
     30  23 Oct 10 GKY Changes to populate and utilize a HELPTABLE for context specific help
    3031
    3132***********************************************************************/
     
    619620    return 0;
    620621
     622  case WM_HELP:
     623    if (hwndHelp)
     624      WinSendMsg(hwndHelp,
     625                 HM_DISPLAY_HELP,
     626                 MPFROM2SHORT(HELP_CMDLINE, 0), MPFROMSHORT(HM_RESOURCEID));
     627    break;
     628
    621629  case WM_COMMAND:
    622630    switch (SHORT1FROMMP(mp1)) {
  • trunk/dll/collect.c

    r1544 r1546  
    7171  15 Sep 09 SHL Use UM_GREP when passing pathname
    7272  17 JAN 10 GKY Changes to get working with Watcom 1.9 Beta (1/16/10). Mostly cast CHAR CONSTANT * as CHAR *.
     73  23 Oct 10 GKY Add menu items for opening directory cnrs based on path of selected item
     74                including the option to use walk directories to select path
    7375
    7476***********************************************************************/
     
    145147#include "fortify.h"
    146148#include "excputil.h"                   // xbeginthread
     149#include "walkem.h"                     // WalkAllDlgProc
    147150
    148151// Data definitions
     
    17491752      case IDM_RESELECT:
    17501753        SelectList(hwnd, FALSE, FALSE, FALSE, NULL, NULL, dcd->lastselection);
     1754        break;
     1755
     1756      case IDM_WALKDIR:
     1757      case IDM_OPENWINDOW:
     1758        {
     1759          CHAR newpath[CCHMAXPATH];
     1760          PCNRITEM pci;
     1761
     1762          pci = (PCNRITEM) CurrentRecord(hwnd);
     1763          if (pci && (INT) pci != -1) {
     1764            strcpy(newpath, pci->pszFileName);
     1765            MakeValidDir(newpath);
     1766          }
     1767          else
     1768            strcpy(newpath, pFM2SaveDirectory);
     1769          if (SHORT1FROMMP(mp1) == IDM_WALKDIR)
     1770            WinDlgBox(HWND_DESKTOP, dcd->hwndParent, WalkAllDlgProc,
     1771                      FM3ModHandle, WALK_FRAME, MPFROMP(newpath));
     1772          if (!*newpath)
     1773            break;
     1774          WinSendMsg(hwnd, UM_OPENWINDOWFORME, MPFROMP(newpath), MPVOID);
     1775        }
    17511776        break;
    17521777
     
    21862211      case IDM_UPDATE:
    21872212      case IDM_COLLECTFROMFILE:
    2188       case IDM_OPENWINDOW:
     2213      //case IDM_OPENWINDOW:
    21892214      case IDM_OPENSETTINGS:
    21902215      case IDM_OPENDEFAULT:
  • trunk/dll/eas.c

    r1498 r1546  
    2525  12 Jul 09 GKY Add xDosQueryAppType and xDosAlloc... to allow FM/2 to load in high memory
    2626  17 JAN 10 GKY Changes to get working with Watcom 1.9 Beta (1/16/10). Mostly cast CHAR CONSTANT * as CHAR *.
     27  23 Oct 10 GKY Added button to allow opening of a new file's eas from the EA dialog.
    2728
    2829***********************************************************************/
     
    5859#include "misc.h"                       // PaintRecessedWindow
    5960#include "fortify.h"
     61#include "getnames.h"                   // insert_filename
     62#include "pathutil.h"                   // ForwardslashToBackslash
    6063
    6164#pragma data_seg(DATA1)
     
    494497            MLEclearall(WinWindowFromID(hwnd, EA_MLE));
    495498            WinShowWindow(WinWindowFromID(hwnd, EA_MLE), FALSE);
    496             WinShowWindow(WinWindowFromID(hwnd, EA_CHANGE), FALSE);
     499            WinShowWindow(WinWindowFromID(hwnd,EA_CHANGE), FALSE);
    497500            WinShowWindow(WinWindowFromID(hwnd, EA_DELETE), FALSE);
    498501            WinShowWindow(WinWindowFromID(hwnd, EA_HEXDUMP), FALSE);
     
    829832  case WM_COMMAND:
    830833    switch (SHORT1FROMMP(mp1)) {
     834    case EA_OPENFILE:
     835      {
     836        CHAR filename[CCHMAXPATH];
     837        CHAR *p;
     838        CHAR **list = NULL;
     839
     840        if (*eap->filename)
     841          strcpy(filename, eap->filename);
     842        WinDismissDlg(hwnd, 1);
     843        ForwardslashToBackslash(filename);
     844        p = strrchr(filename, '\\');
     845        if (p) {
     846          p++;
     847          *p = 0;
     848        }
     849        else
     850          *filename = 0;
     851        strcat(filename, "*");
     852        list = xmalloc(sizeof(CHAR *) * 2, pszSrcFile, __LINE__);
     853       
     854        if (list) {
     855          if (insert_filename(HWND_DESKTOP,filename,TRUE,FALSE) &&
     856              *filename && *filename != '*') {
     857            list[0] = filename;
     858            list[1] = NULL;
     859            WinDlgBox(HWND_DESKTOP,
     860                      HWND_DESKTOP,
     861                      DisplayEAsProc,
     862                      FM3ModHandle,
     863                      EA_FRAME,
     864                      (PVOID)list);
     865          }
     866          else
     867            free(list);
     868        }
     869        break;
     870      }
    831871    case EA_ADD:
    832872      {
  • trunk/dll/extract.c

    r1505 r1546  
    1919  07 Feb 09 GKY Allow user to turn off alert and/or error beeps in settings notebook.
    2020  17 JAN 10 GKY Changes to get working with Watcom 1.9 Beta (1/16/10). Mostly cast CHAR CONSTANT * as CHAR *.
     21  23 Oct 10 GKY Changes to populate and utilize a HELPTABLE for context specific help
    2122
    2223***********************************************************************/
     
    458459
    459460    case IDM_HELP:
     461    case WM_HELP:
    460462      if (hwndHelp)
    461463        WinSendMsg(hwndHelp, HM_DISPLAY_HELP,
  • trunk/dll/fm3dlg.h

    r1491 r1546  
    3737                option to Quick page.
    3838  27 Dec 09 GKY Made command hotkeys user selectable.
     39  23 Oct 10 GKY Added button to allow opening of a new file's eas from the EA dialog.
    3940
    4041***********************************************************************/
     
    258259#define COMP_TOTALRIGHTHDR                                                              21023
    259260#define COMP_SELRIGHTHDR                                                                21024
    260 #define COMP_FILTER                                                                             21025
    261 #define COMP_HIDENOTSELECTED                                                    21026
    262 
    263 #define EA_FRAME                                                                                        21100
    264 #define EA_LISTBOX                                                                              21101
    265 #define EA_TEXT                                                                                 21102
    266 #define EA_ENTRY                                                                                        21103
    267 #define EA_MLE                                                                                          21104
    268 #define EA_CHANGE                                                                                       21105
    269 #define EA_DELETE                                                                                       21106
    270 #define EA_HEXDUMP                                                                              21107
    271 #define EA_ADD                                                                                          21108
    272 #define EA_NAMES                                                                                        21109
    273 #define EA_HELP                                                                                 21110
     261#define COMP_FILTER                                                                     21025
     262#define COMP_HIDENOTSELECTED                                                            21026
     263
     264#define EA_FRAME                                                                        21100
     265#define EA_LISTBOX                                                                      21101
     266#define EA_TEXT                                                                         21102
     267#define EA_ENTRY                                                                        21103
     268#define EA_MLE                                                                          21104
     269#define EA_CHANGE                                                                       21105
     270#define EA_DELETE                                                                       21106
     271#define EA_HEXDUMP                                                                      21107
     272#define EA_ADD                                                                          21108
     273#define EA_NAMES                                                                        21109
     274#define EA_HELP                                                                         21110
     275#define EA_OPENFILE                                                                     21111
    274276
    275277#define EAC_FRAME                                                                                       21200
    276 #define EAC_TEXT                                                                                        21201
     278#define EAC_TEXT                                                                        21201
    277279#define EAC_NAME                                                                                        21202
    278280#define EAC_ASCII                                                                                       21203
  • trunk/dll/fm3dll2.h

    r1488 r1546  
    3232  22 Nov 09 GKY Add LVM.EXE to partition submenu
    3333  21 Dec 09 GKY Added 20 new hot keys for commands.
     34  23 Oct 10 GKY Changes to populate and utilize a HELPTABLE for context specific help
    3435
    3536  Align with spaces only - no tabs please
     
    9091#define ID_HELPTABLE        50
    9192#define ID_HELPSUBTABLE     51
     93#define ID_HELPSUBTABLEA    52
     94#define ID_HELPSUBTABLEB    53
    9295#define ID_BUTTONMENU       99
    9396
     
    393396#define IDM_DATABAR         1163
    394397#define IDM_PARTITIONLVM    1164
     398#define IDM_OPENSUBCNRMENU  1165
    395399
    396400#define IDM_UTILITIESMENU   2000
  • trunk/dll/fm3res.dlg

    r1507 r1546  
    5050                option to Quick page.
    5151  27 Dec 09 GKY Made command hotkeys user selectable.
    52 
     52  23 Oct 10 GKY Added button to allow opening of a new file's eas from the EA dialog.
     53 
    5354***********************************************************************/
    5455
     
    313314DLGTEMPLATE ASEL_FRAME LOADONCALL MOVEABLE DISCARDABLE
    314315BEGIN
    315     DIALOG  "FM/2: Select Archiver", ASEL_FRAME, 16, -16, 159, 120,
     316    DIALOG  "FM/2: Select Archiver", ASEL_FRAME, 36, -16, 159, 120,
    316317            FS_MOUSEALIGN, FCF_TITLEBAR
    317318    BEGIN
     
    15271528DLGTEMPLATE EA_FRAME LOADONCALL MOVEABLE DISCARDABLE
    15281529BEGIN
    1529     DIALOG  "FM/2: EAs", EA_FRAME, 12, 6, 352, 218, WS_VISIBLE | NOT
     1530    DIALOG  "FM/2: EAs", EA_FRAME, 52, 56, 352, 218, WS_VISIBLE | NOT
    15301531            WS_SAVEBITS, FCF_SYSMENU | FCF_TITLEBAR | FCF_MINBUTTON |
    15311532            FCF_TASKLIST
    15321533    BEGIN
     1534        PUSHBUTTON      "~Open file", EA_OPENFILE, 8, 204, 40, 12,
     1535                        BS_NOPOINTERFOCUS
    15331536        CTEXT           "These are the EA types this object contains -- pick"
    1534                         " one.", EA_HELP, 8, 206, 336, 8, DT_VCENTER
     1537                        " one.", EA_HELP, 58, 206, 236, 8, DT_VCENTER
    15351538                        PRESPARAMS PP_FOREGROUNDCOLOR, 0x00FFFFFFL
    15361539                        PRESPARAMS PP_BACKGROUNDCOLOR, 0x00000080L
  • trunk/dll/fm3res.rc

    r1529 r1546  
    5555  27 Dec 09 GKY Strings for command.c changes
    5656  09 MAY 10 JBS Ticket 434: Message box text improvements.
    57 
     57  23 Oct 10 GKY Add menu items for opening directory cnrs based on path of selected item
     58                including the option to use walk directories to select path
     59  23 Oct 10 GKY Changes to populate and utilize a HELPTABLE for context specific help.             
     60 
    5861***********************************************************************/
    5962
     
    653656  VK_F10,     SC_MAXIMIZE,            SYSCOMMAND,CONTROL,ALT,VIRTUALKEY
    654657  VK_F11,     SC_HIDE,                SYSCOMMAND,CONTROL,ALT,VIRTUALKEY
    655   VK_F1,      IDM_HELP,               VIRTUALKEY
     658//  VK_F1,      IDM_HELP,               VIRTUALKEY
    656659  VK_F2,      IDM_COLLECTOR,          VIRTUALKEY
    657660  VK_F3,      IDM_KILLME,             CONTROL,VIRTUALKEY
     
    15311534         MENUITEM "~Settings\tF7",   IDM_OPENSETTINGS
    15321535  }
    1533   SUBMENU "Create objects",     IDM_OBJECTSUBMENU
     1536  SUBMENU  "Open directory container",     IDM_OPENSUBCNRMENU
     1537  {
     1538         MENUITEM "Open container", IDM_OPENWINDOW
     1539         MENUITEM "Walk to open",   IDM_WALKDIR
     1540  }
     1541  SUBMENU "Create objects",     IDM_OBJECTSUBMENU       
    15341542  {
    15351543         MENUITEM "~Shadows...",     IDM_SHADOW
     
    33813389HELPTABLE ID_HELPTABLE
    33823390{
     3391   HELPITEM MAIN_FRAME,      ID_HELPSUBTABLE,  HELP_MAIN
     3392   HELPITEM ASS_FRAME,       ID_HELPSUBTABLEA, HELP_ASSOC
     3393   HELPITEM EXEC_FRAME,      ID_HELPSUBTABLEB, HELP_CMDLINE
     3394   HELPITEM ASEL_FRAME,      ID_HELPSUBTABLEA, HELP_ARCHIVERS
     3395   HELPITEM ASEL_EDIT_FRAME, ID_HELPSUBTABLEA, HELP_EDITARC
    33833396}
    33843397
    33853398HELPSUBTABLE ID_HELPSUBTABLE
    33863399{
     3400   HELPSUBITEM COMMAND_LINE, HELP_HINTSCMD
     3401   
     3402}
     3403
     3404HELPSUBTABLE ID_HELPSUBTABLEA
     3405{
     3406}
     3407
     3408HELPSUBTABLE ID_HELPSUBTABLEB
     3409{
    33873410}
    33883411
  • trunk/dll/init.c

    r1544 r1546  
    9797  17 JAN 10 GKY Changes to get working with Watcom 1.9 Beta (1/16/10). Mostly cast CHAR CONSTANT * as CHAR *.
    9898  09 MAY 10 JBS Ticket 434: Make fDontSuggestAgain a "global" flag, not a per app flag
     99  23 Oct 10 GKY Changes to populate and utilize a HELPTABLE for context specific help
    99100
    100101***********************************************************************/
     
    930931  hini.idActionBar = 0;
    931932  hini.pszHelpWindowTitle = (PSZ)GetPString(IDS_FM2HELPTITLETEXT);
     933  hini.hmodHelpTableModule = FM3ModHandle;
    932934  hini.fShowPanelId = CMIC_HIDE_PANEL_ID;
    933935  hini.pszHelpLibraryName = "FM3.HLP";
  • trunk/dll/ipf/arclist.ipf

    r1471 r1546  
    1010.* 31 Jul 04 SHL Rework file name position description
    1111.* 28 Sep 09 SHL Minor updates
     12.* 23 Oct 10 GKY Changes to populate and utilize a HELPTABLE for context specific help
    1213.*
    1314.***********************************************************************
     
    142143(usually) compressed data that represents, and allows recreation of,
    143144normal (uncompressed) files. These archiver programs are widely used to
    144 create archive files for downloading from
    145 the Internet, and to extract from those archive files once downloaded.
    146 They're also used to create archives locally for backup purposes, as the
    147 files thus created are smaller than the original files and contain many
    148 other files within them.
     145create archive files for downloading from the Internet, and to extract
     146from those archive files once downloaded. They're also used to create
     147archives locally for backup purposes, as the files thus created are
     148smaller than the original files and contain many other files within them.
     149:p.
     150FM/2 comes with a collection of archiver discriptions contained in the file
     151:link reftype=hd res=100130.ARCHIVER.BB2:elink.. However FM/2 doesn't
     152include the archivers. You will need to obtain the archiver and place it
     153in your "PATH" in order for it to work. Versions of zip and unzip are included
     154with eCS. Because of this some of the archivers on the list won't actually be
     155available for use. You can set a default archiver for archiving on the
     156:link reftype=hd res=99940.Archiver page:elink. of the settings notebook.
     157See :link reftype=hd res=90300.Build an archive:elink. for details on
     158creating an archive.
    149159:p.
    150160Following is a partial list of OS/2 archivers available at the time of
  • trunk/dll/ipf/config.ipf

    r1518 r1546  
    446446:i1 id=aboutArcBB2.ArchiverBB2 Structure
    447447:p.
    448 ARCHIVER.BB2 is a text file and can be viewd or edited with any text editor. It contains are three types of lines&colon.
     448ARCHIVER.BB2 is a text file and can be viewd or edited with any text editor.
     449It contains are three types of lines&colon.
    449450:ol compact.
    450 :li.The first line in the file is the number of lines per archiver definition in the ARCHIVER.BB2 file.
     451:li.The first line in the file is the number of lines per archiver definition
     452in the ARCHIVER.BB2 file.
    451453It is very important; do not change it.
    452454It allows modifications to the file format to be transparent to older programs.
  • trunk/dll/mainwnd.c

    r1544 r1546  
    108108  11 Apr 10 GKY Fix drive tree rescan failure and program hang caused by event sem
    109109                never being posted
     110  23 Oct 10 GKY Changes to populate and utilize a HELPTABLE for context specific help
    110111
    111112***********************************************************************/
     
    63926393
    63936394  case WM_HELP:
    6394     WinSendMsg(hwndHelp, HM_HELP_CONTENTS, MPVOID, MPVOID);
     6395    if (hwndHelp)
     6396      PostMsg(hwndHelp, HM_DISPLAY_HELP, MPFROMSHORT(1), MPFROMSHORT(HM_RESOURCEID));
    63956397    break;
    63966398
  • trunk/dll/misc.c

    r1544 r1546  
    6666                Added load_inicommand to load the IDs from the ini file.
    6767  17 JAN 10 GKY Changes to get working with Watcom 1.9 Beta (1/16/10). Mostly cast CHAR CONSTANT * as CHAR *.
     68  23 Oct 10 GKY Add menu items for opening directory cnrs based on path of selected item
     69                including the option to use walk directories to select path
    6870
    6971***********************************************************************/
     
    20112013                            fDefaultDeletePerm ? IDM_PERMDELETE : IDM_DELETE);
    20122014      SetConditionalCascade(CollectorFileMenu, IDM_OPENSUBMENU,
    2013                             IDM_OPENDEFAULT);
     2015                            IDM_OPENDEFAULT);
     2016      SetConditionalCascade(CollectorFileMenu, IDM_OPENSUBCNRMENU,
     2017                            IDM_OPENWINDOW);
    20142018      SetConditionalCascade(CollectorFileMenu, IDM_OBJECTSUBMENU, IDM_SHADOW);
    20152019      if (fWorkPlace) {
  • trunk/dll/notebook.c

    r1505 r1546  
    289289                         (PVOID) & pat) || !pat || !pat->id || !*pat->id) {
    290290            if (!fAlertBeepOff)
    291             DosBeep(250, 100);          // Complain
     291              DosBeep(250, 100);          // Complain
    292292            WinCheckButton(hwnd, CFGA_DEFARC, FALSE);
    293293          }
Note: See TracChangeset for help on using the changeset viewer.