cbklib

Check-in [7dd496bd2c]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Final tweaks of registration, xplat
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1:7dd496bd2cb7ea8a38b525f1db391d0d62bc2bdf
User & Date: admin 2015-10-13 10:52:41
Context
2015-11-14
04:47
Update software update package check-in: 49a6b6157d user: admin tags: trunk
2015-10-13
10:52
Final tweaks of registration, xplat check-in: 7dd496bd2c user: admin tags: trunk
2015-10-09
02:06
Updates of various libs check-in: 7360c31fb1 user: admin tags: trunk
Changes
Hide Diffs Unified Diffs Show Whitespace Changes Patch

Changes to regproc/regproc.tcl.

233
234
235
236
237
238
239

240
241
242
243
244
245
246
...
256
257
258
259
260
261
262

263
264
265
266
267
268
269

270
271
272
273
274
275
276
277
278
279
280
...
316
317
318
319
320
321
322

323
324
325
326
327
328
329
...
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
    proc setLic {} {
	variable serial
	variable serialbase
	variable datadir
	variable appname
	variable regwindow
	variable appstore


	if {$serial == ""} {
	    tk_messageBox -icon warning -title "Incorrect Serial Number" -message "Incorrect Serial Number" -detail "Incorrect serial number. The application will exit now." -parent .number
	    exit
	}

	set count 20000
................................................................................
	puts $output
	
	if {$output >= 0} {
	    cd $datadir
	    set lic [open $datadir/lic.dat w]
	    puts $lic "$serial"
	    close $lic

	    tk_messageBox -icon info -title "Thank You" -message "Thank You" -detail "Thank you for registering $appname." -parent .number
	    destroy .number
	    #display window that was hidden
	    catch {wm deiconify .}

	} else {
	    if {$expired == 1} {

		tk_messageBox -icon warning -title "Incorrect Serial Number" -message "Incorrect Serial Number" -detail "Incorrect serial number. The application will exit now." -parent .number
		exit
	    }
	    
	    tk_messageBox -icon warning -title "Incorrect Serial Number" -message "Incorrect Serial Number" -detail "Incorrect serial number. Please try again." -parent .number
	    regproc::getReg
	}
    }



................................................................................
	variable appstore
	variable expired
	variable appname
	variable licensetitle

	set licensetitle "License" 


	toplevel .number
	wm title .number $licensetitle
	regproc::makeModal .number
	wm resizable .number 0 0

	wm withdraw .number
	wm transient .number .
................................................................................
	ttk::frame .number.bottom.upper
	pack .number.bottom.upper -side top -fill both -expand no


	ttk::frame .number.bottom.lower -padding 5
	pack .number.bottom.lower -side bottom -fill both -expand no

	bind .number <Return> {regproc::setLic; destroy .number; raise .}
	ttk::button .number.bottom.lower.install -text "Register" -default active -command {regproc::setLic; destroy .number; raise .}
	ttk::button .number.bottom.lower.cancel -text "Cancel" -command "regproc::exitIfExpired; destroy .number; raise ."
	pack  .number.bottom.lower.install .number.bottom.lower.cancel  -side right -fill both -expand no
	
	::tk::PlaceWindow .number widget .

	wm deiconify .number
	focus .number.bottom.lower.install
	if {[tk windowingsystem] eq "aqua"} {







>







 







>







>



|







 







>







 







|
|
|







233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
...
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
...
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
...
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
    proc setLic {} {
	variable serial
	variable serialbase
	variable datadir
	variable appname
	variable regwindow
	variable appstore
	variable expired

	if {$serial == ""} {
	    tk_messageBox -icon warning -title "Incorrect Serial Number" -message "Incorrect Serial Number" -detail "Incorrect serial number. The application will exit now." -parent .number
	    exit
	}

	set count 20000
................................................................................
	puts $output
	
	if {$output >= 0} {
	    cd $datadir
	    set lic [open $datadir/lic.dat w]
	    puts $lic "$serial"
	    close $lic
		grab release .number
	    tk_messageBox -icon info -title "Thank You" -message "Thank You" -detail "Thank you for registering $appname." -parent .number
	    destroy .number
	    #display window that was hidden
	    catch {wm deiconify .}

	} else {
	    if {$expired == 1} {
		grab release .number
		tk_messageBox -icon warning -title "Incorrect Serial Number" -message "Incorrect Serial Number" -detail "Incorrect serial number. The application will exit now." -parent .number
		exit
	    }
	    grab release .number
	    tk_messageBox -icon warning -title "Incorrect Serial Number" -message "Incorrect Serial Number" -detail "Incorrect serial number. Please try again." -parent .number
	    regproc::getReg
	}
    }



................................................................................
	variable appstore
	variable expired
	variable appname
	variable licensetitle

	set licensetitle "License" 

	catch {destroy .number}
	toplevel .number
	wm title .number $licensetitle
	regproc::makeModal .number
	wm resizable .number 0 0

	wm withdraw .number
	wm transient .number .
................................................................................
	ttk::frame .number.bottom.upper
	pack .number.bottom.upper -side top -fill both -expand no


	ttk::frame .number.bottom.lower -padding 5
	pack .number.bottom.lower -side bottom -fill both -expand no

	bind .number <Return> {grab release .number; regproc::setLic;  raise .}
	ttk::button .number.bottom.lower.install -text "Register" -default active -command {grab release .number; regproc::setLic; raise .}
	ttk::button .number.bottom.lower.cancel -text "Cancel" -command "grab release .number; regproc::exitIfExpired; destroy .number; raise ."
	pack  .number.bottom.lower.install .number.bottom.lower.cancel  -side right -fill both -expand no
	
	::tk::PlaceWindow .number widget .

	wm deiconify .number
	focus .number.bottom.lower.install
	if {[tk windowingsystem] eq "aqua"} {