home *** CD-ROM | disk | FTP | other *** search
/ Visual Basic Source Code / Visual Basic Source Code.iso / vbsource / jpi / resoluti.frm (.txt) < prev    next >
Encoding:
Visual Basic Form  |  1998-01-29  |  2.1 KB  |  73 lines

  1. VERSION 5.00
  2. Begin VB.Form ResolutionSelectionForm 
  3.    BorderStyle     =   3  'Fixed Dialog
  4.    Caption         =   "Graphics Mode"
  5.    ClientHeight    =   2055
  6.    ClientLeft      =   2745
  7.    ClientTop       =   1605
  8.    ClientWidth     =   2910
  9.    LinkTopic       =   "Form1"
  10.    MaxButton       =   0   'False
  11.    MinButton       =   0   'False
  12.    ScaleHeight     =   2055
  13.    ScaleWidth      =   2910
  14.    StartUpPosition =   2  'CenterScreen
  15.    Begin VB.CommandButton EnterProgramButton 
  16.       Caption         =   "Enter Game"
  17.       Height          =   255
  18.       Left            =   120
  19.       TabIndex        =   1
  20.       Top             =   1680
  21.       Width           =   1095
  22.    End
  23.    Begin VB.ListBox ResolutionSelectionList 
  24.       Height          =   1425
  25.       Left            =   120
  26.       TabIndex        =   0
  27.       Top             =   120
  28.       Width           =   2655
  29.    End
  30. Attribute VB_Name = "ResolutionSelectionForm"
  31. Attribute VB_GlobalNameSpace = False
  32. Attribute VB_Creatable = False
  33. Attribute VB_PredeclaredId = True
  34. Attribute VB_Exposed = False
  35. Private Sub EnterProgramButton_Click()
  36. Call LaunchIt(ResolutionSelectionList.ListIndex)
  37. End Sub
  38. Private Sub Form_Load()
  39. ResolutionSelectionList.AddItem "320x200"
  40. ResolutionSelectionList.AddItem "640x400"
  41. ResolutionSelectionList.AddItem "640x480"
  42. ResolutionSelectionList.AddItem "800x600"
  43. ResolutionSelectionList.ListIndex = 0
  44. End Sub
  45. Private Sub ResolutionSelectionList_DblClick()
  46. Call LaunchIt(ResolutionSelectionList.ListIndex)
  47. End Sub
  48. Private Sub ResolutionSelectionList_KeyDown(KeyCode As Integer, Shift As Integer)
  49. If KeyCode = KEY_ENTER Then
  50.   Call LaunchIt(ResolutionSelectionList.ListIndex)
  51. End If
  52. End Sub
  53. Private Sub LaunchIt(ResMode)
  54. Select Case ResMode
  55. Case 0
  56.   Call GraphicsEngine.ChangeGraphicsMode(320, 200, 16)
  57.   Unload Me
  58.   Call Main
  59. Case 1
  60.   Call GraphicsEngine.ChangeGraphicsMode(640, 400, 16)
  61.   Unload Me
  62.   Call Main
  63. Case 2
  64.   Call GraphicsEngine.ChangeGraphicsMode(640, 480, 16)
  65.   Unload Me
  66.   Call Main
  67. Case 3
  68.   Call GraphicsEngine.ChangeGraphicsMode(800, 600, 16)
  69.   Unload Me
  70.   Call Main
  71. End Select
  72. End Sub
  73.