alien_fx_fiend

QueryBlocker.ini

Jun 26th, 2019
220
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
mIRC 19.32 KB | None | 0 0
  1. alias ShowError {
  2.   dialog -m AMSGError AMSGError
  3. }
  4. dialog AMSGError {
  5.   title "Error"
  6.   option dbu
  7.   size 80 95 80 38
  8.   box "",9, 1 0 78 22
  9.   button "Ok",10, 1 24 78 12, cancel
  10.   text %AMSGError,11, 3 5 74 16, center
  11. }
  12. on 1:open:?:{
  13.   if (%QueryControl == off) halt
  14.   haltdef
  15.   if (($readini(ExceptionList.ini,Nick,$nick)) || ($readini(ExceptionList.ini,Address,$address($nick,2)) != $null)) return
  16.   close -m $nick
  17.   if (($readini(ExceptionList.ini,INick,$nick)) || ($readini(ExceptionList.ini,IAddress,$address($nick,2)) != $null)) return
  18.   if (($dialog(QueryControl)) && (%NotifyOtherPM == 1)) { echo -a 12[4AV2 Query Control12]10 $nick sent you a query while the PM Blocker dialog has already opened. | return }
  19.   set %QueryNick $nick
  20.   if ($comchan($nick,0) == 0) set %QueryAddress UnknownAddress
  21.   else set %QueryAddress $address($nick,2)
  22.   set %QueryMessage $1-
  23.   set %QueryTime $($Timestamp,2)
  24.   writenextini QueryControl.ini All %QueryNick said: %QueryMessage at $fulldate
  25.   msg $nick 12[4AV2 Query Control12]10 $+ $iif(%OnOpen,%OnOpen,You have activated my Query Control $+ $chr(44) please wait for a response.)
  26.   dialog -m QueryControl QueryControl
  27.   if (%AutoReject == on) { .timerReject $+ $Nick 1 %QueryInterval QueryReject $nick }
  28. }
  29. Alias QueryReject {
  30.   close -m $1
  31.   if (%AutoRejectReason) msg $1 12[4AV2 Query Control12]10 Your message got rejected reason being: %AutoRejectReason $+ .)
  32.   else msg $1 12[4AV2 Query Control12]10 Your message got rejected $+ $iif(%RejectReason,$chr(44) the reason being: %RejectReason,.)
  33.   if ($dialog(QueryControl)) { UnsetQuery | dialog -x QueryControl }
  34. }
  35. dialog QueryControl {
  36.   title "AV2 Query Control"
  37.   option dbu
  38.   size 160 175 140 155
  39.   box "User",1, 1 1 47 22
  40.   edit %QueryNick,2, 5 9 40 10, read autohs
  41.   box "Address",3, 60 1 81 22
  42.   edit %QueryAddress,4, 63 9 72 10, read autohs
  43.   box "Message",5, 1 25 140 22
  44.   edit %QueryMessage,6, 5 33 130 10, read autohs
  45.   button "Accept",7, 5 53 25 12
  46.   button "Reject",8, 40 53 25 12
  47.   button "Ignore",9, 75 53 25 12
  48.   button "Silence",10, 110 53 25 12
  49.   box "",11,1 48 140 20
  50.   box "Exception list",12,1 73 62 20
  51.   button "Add nick",13, 5 80 25 10
  52.   button "Add host",14, 35 80 25 10
  53.   box "Query Ignore",15,78 73 62 20
  54.   button "Nick",16, 82 80 25 10
  55.   button "Host",17, 112 80 25 10
  56.   check "Enable",18, 5 103 25 8
  57.   text "Interval (seconds):",19,63 103 55 10
  58.   combo 20, 111 101 25 10, drop
  59.   box "Auto reject",21,1 95 139 20
  60.   button "Ok",22, 5 135 25 13
  61.   button "Logs",28, 42 135 25 13
  62.   button "Options",23, 78 135 25 13
  63.   button "Cancel",24, 112 135 25 13, cancel
  64.   box "",25,1 130 140 20
  65.   edit %RejectReason,26,5 119 130 10
  66.   box "",27,1 113 140 19
  67. }
  68. on 1:dialog:QueryControl:init:0:{
  69.   did -i QueryControl 20 1 10 | did -i QueryControl 20 2 20 |  did -i QueryControl 20 3 30 | did -i QueryControl 20 4 45 | did -i QueryControl 20 5 60 | did -i QueryControl 20 6 90 | did -i QueryControl 20 7 180 | did -i QueryControl 20 8 300 | did -i QueryControl 20 9 600
  70.   if (%AutoReject == on) { did -c QueryControl 18 | did -e QueryControl 20 | did -c QueryControl 20 %IntervalNum }
  71.   else did -b QueryControl 20
  72. }
  73. on *:dialog:QueryControl:sclick:*:{
  74.   if ($did == 7) { .timerReject $+ %Querynick off | set %RejectReason $did(26) | query %QueryNick | echo %QueryNick %QueryTime < $+ %QueryNick $+ > %QueryMessage | msg %QueryNick 12[4AV2 Query Control12]10 Your message has been accepted, you may proceed. | UnsetQuery | dialog -x QueryControl }
  75.   if ($did == 8) { set %RejectReason $did(26) | msg %QueryNick 12[4AV2 Query Control12]10 Your message got rejected $+ $iif(%RejectReason,$chr(44) the reason being:11 %RejectReason, $+ .) | .timerReject $+ %QueryNick off | UnsetQuery | dialog -x QueryControl }
  76.   if ($did == 9) { ignore %QueryAddress | .timer $+ %QueryNick $+ Ignore 1 600 ignore -r %QueryAddress }
  77.   if ($did == 10) { silence + $+ %QueryAddress | .timer $+ %QueryNick $+ Silence 1 600 silence - $+ %QueryAddress }
  78.   if ($did == 13) {
  79.     if ($readini(ExceptionList.ini,Nick,%QueryNick) == $null) {  writeini -n ExceptionList.ini Nick %QueryNick $asctime($ctime,dddd mmmm dd $+ $chr(44) yyyy  hh:nn:sstt) | msg %QueryNick 12[4AV2 Query Control12]10 Your nick has been added to my exception list, fell free to talk now. }
  80.     else { set %AMSGError That nick is already excempt from the Query Control. | ShowError | return }
  81.   }
  82.   if ($did == 14) {
  83.     if (%QueryAddress == Unknown due to lack of common channels) { set %AMSGError The address is unknown; therefore, you cannot add it. | ShowError | return }
  84.     if ($readini(ExceptionList.ini,Address,%QueryAddress) == $null) { writeini -n ExceptionList.ini Address %QueryAddress $asctime($ctime,dddd mmmm dd $+ $chr(44) yyyy  hh:nn:sstt) | msg %QueryNick 12[4AV2 Query Control12]10 Your host has been added to my exception list, fell free to talk now. }
  85.     else { set %AMSGError That host is already excempt from the Query Control. | ShowError | return }
  86.   }
  87.   if ($did == 16) {
  88.     if ((!%QueryNick) && (!%QueryAddress)) { set %AMSGError There is nothing to ignore. | ShowError | return }
  89.     did -b $dname 16 | if ($readini(ExceptionList.ini,INick,%QueryNick) == $null) {  writeini -n ExceptionList.ini INick %QueryNick $asctime($ctime,dddd mmmm dd $+ $chr(44) yyyy  hh:nn:sstt) }
  90.   }
  91.   if ($did == 17) {
  92.     if ((!%QueryNick) && (!%QueryAddress) && (!%QueryMessage)) { set %AMSGError There is nothing to log. | ShowError | return }
  93.     did -b $dname 17 | $readini(ExceptionList.ini,IAddress,%QueryAddress) == $null) { writeini -n ExceptionList.ini IAddress %QueryAddress $asctime($ctime,dddd mmmm dd $+ $chr(44) yyyy  hh:nn:sstt) }
  94.   }
  95.   if ($did == 18) {
  96.     if ($did(18).state == 1) { did -e QueryControl 20 | set %AutoReject on }
  97.     else { did -b QueryControl 20 | set %AutoReject off | unset %IntervalNum }
  98.   }
  99.   if ($did == 22) {
  100.     if (%OkButton == QuietClose) dialog -x $dname
  101.     if ((%AutoReject == on) && ($did(20) == $null)) { set %AMSGError You must specify an interval to auto-reject incoming queries. | ShowError | return }
  102.     set %RejectReason $did(26) | set %QueryInterval $did(20)
  103.     if ($did(20) < 40) set %IntervalNum $calc($did(20) /10)
  104.     elseif ($did(20) == 45) set %IntervalNum 4
  105.     elseif ($did(20) == 60) set %IntervalNum 5
  106.     elseif ($did(20) == 90) set %IntervalNum 6
  107.     elseif ($did(20) == 180) set %IntervalNum 7
  108.     elseif ($did(20) == 300) set %IntervalNum 8
  109.     elseif ($did(20) == 600) set %IntervalNum 9
  110.     if (%OkButton == Apply) { UnsetQuery | dialog -x QueryControl }
  111.     elseif (%OkButton == QuietOpen) { query %QueryNick | echo %QueryNick %QueryTime < $+ %QueryNick $+ > %QueryMessage }
  112.     elseif (%OkButton == Random) {
  113.       set %RandVar $r(1,3)
  114.       if (%RandVar == 1) { query %QueryNick | echo %QueryNick %QueryTime < $+ %QueryNick $+ > %QueryMessage }
  115.       elseif %RandVar == 2) { dialog -x $dname }
  116.       else { UnsetQuery | dialog -x QueryControl }
  117.     }
  118.     else { UnsetQuery | dialog -x QueryControl }
  119.   }
  120.   if ($did == 23) { UnsetQuery | dialog -x Querycontrol | dialog -m QueryControlOptions2 QueryControlOptions2 }
  121.   if ($did == 28) { UnsetQuery | dialog -x Querycontrol | dialog -m QueryControlOptions QueryControlOptions }
  122. }
  123. alias UnsetQuery { unset %QueryNick | unset %QueryAddress | unset %QueryMessage }
  124. dialog QueryControlOptions {
  125.   showrecent
  126.   title "AV2 Query Control Exception and Ignore lists"
  127.   size -1 -1 220 180
  128.   option dbu
  129.   text "Oldest                        To                    Newest                      Nicks:" 1,5 13 26 55
  130.   combo 2,28 11 55 55
  131.   text "Oldest                        To                    Newest                      Hosts:" 3,98 13 26 50
  132.   combo 4,125 11 90 55
  133.   text "Oldest                        To                    Newest                      Nicks:" 5,5 95 26 50
  134.   text "Oldest                        To                    Newest                      Hosts:" 17,98 95 26 50
  135.   combo 6,28 95 55 55, autohs
  136.   combo 18,125 95 90 55
  137.   button "Add",7,27 65 20 10
  138.   button "Delete",8,63 65 20 10
  139.   button "Add",9,135 65 20 10
  140.   button "Delete",10,180 65 20 10
  141.   button "Add",19,27 150 20 10
  142.   button "Delete",20,63 150 20 10
  143.   button "Add",21,135 150 20 10
  144.   button "Delete",22,180 150 20 10
  145.   box "Exceptions",12, 1 1 217 77
  146.   box "Ignore",13,1 85 217 77
  147.   button "Ok",14,10 165 25 10,cancel
  148.   button "Options"15,95 165 25 10
  149.   button "Cancel",16,185 165 25 10,cancel
  150. }
  151.  
  152. on 1:dialog:QueryControlOptions:init:0:{
  153.   set %x 1
  154.   while ($ini(ExceptionList.ini,Nick,%x)) {
  155.     did -i QueryControlOptions 2 %x $ini(ExceptionList.ini,Nick,%x)
  156.     inc %x
  157.   }
  158.   set %x 1
  159.   while ($ini(ExceptionList.ini,Address,%x)) {
  160.     did -i QueryControlOptions 4 %x $ini(ExceptionList.ini,Address,%x)
  161.     inc %x
  162.   }
  163.   set %x 1
  164.   while ($ini(ExceptionList.ini,INick,%x)) {
  165.     did -i QueryControlOptions 6 %x $ini(ExceptionList.ini,INick,%x)
  166.     inc %x
  167.   }
  168.   set %x 1
  169.   while ($ini(ExceptionList.ini,IAddress,%x)) {
  170.     did -i QueryControlOptions 18 %x $ini(ExceptionList.ini,IAddress,%x)
  171.     inc %x
  172.   }
  173. }
  174. on *:dialog:QueryControlOptions:sclick:*:{
  175.   if ($did == 7) {
  176.     if ($did(2) == $null) { set %AMSGError No user specified to add to the exception list. | ShowError | return }
  177.     if $readini(ExceptionList.ini,Nick,$did(2)) { set %AMSGError That user already appears to be in the exception list. | ShowError | return }
  178.     writeini ExceptionList.ini Nick $did(2) $asctime($ctime,dddd mmmm dd $+ $chr(44) yyyy  hh:nn:sstt)
  179.     did -r QueryControlOptions 2
  180.     dialog -x QueryControlOptions
  181.     dialog -m QueryControlOptions QueryControlOptions
  182.   }
  183.   if ($did == 8) {
  184.     if ($did(2) == $null) { set %AMSGError No user specified to delete from the exception list. | ShowError | return }
  185.     if ($readini(ExceptionList.ini,Nick,$did(2)) == $null) { set %AMSGError That user does not appear to be in the exception list. | ShowError | return }
  186.     remini ExceptionList.ini Nick $did(2)
  187.     did -r QueryControlOptions 2
  188.     dialog -x QueryControlOptions
  189.     dialog -m QueryControlOptions QueryControlOptions
  190.   }
  191.   if ($did == 9) {
  192.     if ($did(4) == $null) { set %AMSGError No host specified to add to the exception list. | ShowError | return }
  193.     if ($left($did(4),4) != *!*@) { set %AMSGError The host must be in type 2 format (*!*@Example.com). | ShowError | return }
  194.     if $readini(ExceptionList.ini,Address,$did(4)) { set %AMSGError That host already appears to be in the exception list. | ShowError | return }
  195.     writeini ExceptionList.ini Address $did(4) $asctime($ctime,dddd mmmm dd $+ $chr(44) yyyy  hh:nn:sstt)
  196.     did -r QueryControlOptions 4
  197.     dialog -x QueryControlOptions
  198.     dialog -m QueryControlOptions QueryControlOptions
  199.   }
  200.   if ($did == 10) {
  201.     if ($did(4) == $null) { set %AMSGError No host specified to delete from the exception list. | ShowError | return }
  202.     if ($readini(ExceptionList.ini,Address,$did(4)) == $null) { set %AMSGError That host does not appear to be in the exception list. | ShowError | return }
  203.     remini ExceptionList.ini Address $did(4)
  204.     did -r QueryControlOptions 4
  205.     dialog -x QueryControlOptions
  206.     dialog -m QueryControlOptions QueryControlOptions
  207.   }
  208.   if ($did == 11) {
  209.     if ($did(6) == $null) { set %AMSGError No logged message specified to delete from the logs. | ShowError | return }
  210.     if ($InList(Message,$did(6)) == no) { set %AMSGError That message does not appear to be in the log list. | ShowError | return }
  211.     RemoveFromList All $did(6)
  212.     did -r QueryControlOptions 6
  213.     dialog -x QueryControlOptions
  214.     dialog -m QueryControlOptions QueryControlOptions
  215.   }
  216.   if ($did == 15) {
  217.     dialog -x QueryControlOptions
  218.     dialog -m QueryControlOptions2 QueryControlOptions2
  219.   }
  220.   if ($did == 19) {
  221.     if ($did(6) == $null) { set %AMSGError No user specified to add to the ignore list. | ShowError | return }
  222.     if $readini(ExceptionList.ini,INick,$did(6)) { set %AMSGError That user already appears to be in the exception list. | ShowError | return }
  223.     writeini ExceptionList.ini INick $did(6) $asctime($ctime,dddd mmmm dd $+ $chr(44) yyyy  hh:nn:sstt)
  224.     did -r QueryControlOptions 6
  225.     dialog -x QueryControlOptions
  226.     dialog -m QueryControlOptions QueryControlOptions
  227.   }
  228.   if ($did == 20) {
  229.     if ($did(6) == $null) { set %AMSGError No user specified to delete from the ignore list. | ShowError | return }
  230.     if ($readini(ExceptionList.ini,INick,$did(6)) == $null) { set %AMSGError That user does not appear to be in the exception list. | ShowError | return }
  231.     remini ExceptionList.ini INick $did(6)
  232.     did -r QueryControlOptions 6
  233.     dialog -x QueryControlOptions
  234.     dialog -m QueryControlOptions QueryControlOptions
  235.   }
  236.   if ($did == 14) dialog -x QueryControlOptions
  237.   if ($did == 21) {
  238.     if ($did(18) == $null) { set %AMSGError No host specified to add to the ignore list. | ShowError | return }
  239.     if ($left($did(4),4) != *!*@) { set %AMSGError The host must be in type 2 format (*!*@Example.com). | ShowError | return }
  240.     if $readini(ExceptionList.ini,IAddress,$did(18)) { set %AMSGError That host already appears to be in the exception list. | ShowError | return }
  241.     writeini ExceptionList.ini IAddress $did(18) $asctime($ctime,dddd mmmm dd $+ $chr(44) yyyy  hh:nn:sstt)
  242.     did -r QueryControlOptions 18
  243.     dialog -x QueryControlOptions
  244.     dialog -m QueryControlOptions QueryControlOptions
  245.   }
  246.   if ($did == 22) {
  247.     if ($did(18) == $null) { set %AMSGError No host specified to delete from the ignore list. | ShowError | return }
  248.     if ($readini(ExceptionList.ini,IAddress,$did(18)) == $null) { set %AMSGError That host does not appear to be in the exception list. | ShowError | return }
  249.     remini ExceptionList.ini IAddress $did(18)
  250.     did -r QueryControlOptions 18
  251.     dialog -x QueryControlOptions
  252.     dialog -m QueryControlOptions QueryControlOptions
  253.   }
  254. }
  255. alias RemoveFromList {
  256.   set %x 1
  257.   set %y 0
  258.   while ($ini(QueryControl.ini,$1,%x)) {
  259.     if (%y < $ini(QueryControl.ini,$1,%x)) set %y $ini(QueryControl.ini,$1,%x)
  260.     inc %x
  261.   }
  262.   set %x 1
  263.   while (%x <= %y) {
  264.     if ($readini(querycontrol.ini,$1,%x) == $2-) { remini QueryControl.ini $1 %x | return }
  265.     inc %x
  266.   }
  267. }
  268. alias InList {
  269.   set %x 1
  270.   set %y 0
  271.   while ($ini(QueryControl.ini,$1,%x)) {
  272.     if (%y < $ini(QueryControl.ini,$1,%x)) set %y $ini(QueryControl.ini,$1,%x)
  273.     inc %x
  274.   }
  275.   set %x 1
  276.   while (%x <= %y) {
  277.     if ($readini(querycontrol.ini,$1,%x) == $2-) { return yes }
  278.     inc %x
  279.   }
  280.   return no
  281. }
  282. dialog QueryControlOptions2 {
  283.   showrecent
  284.   title "AV2 Query Control Options"
  285.   size -1 -1 227 105
  286.   option dbu
  287.   text "Ok button function:",1, 5 15 55 10
  288.   combo 2, 57 13 120 10, drop
  289.   text "Auto Reject reason:"3,5 30 55 10
  290.   edit %AutoRejectReason,4,57 28 120 10
  291.   text "Rejection    reason:",5,5 45 55 10
  292.   edit %RejectReason,6,57 43 120 10
  293.   text "Open  query   msg:",7,5 62 50 10
  294.   edit %OnOpen,8,57 60 120 10
  295.   box "Messaging",9,1 1 180 85
  296.   button "Enable",10,182 12 20 10
  297.   button "Disable",11,204 12 22 10
  298.   button "Logs",12,182 27 20 10
  299.   button "Set up",13,204 27 22 10
  300.   button "Clear",14,182 43 20 10
  301.   button "Default",15,204 43 22 10
  302.   button "Help",16,182 60 20 10
  303.   button "About",17,204 60 22 10
  304.   button "Ok",18,10 90 25 10
  305.   button "Cancel",19,195 90 25 10,cancel
  306.   text "Notify you when somebody is PMing while blocker is activated:",20,5 76 155 10
  307.   button "Yes",21,182 75 20 10
  308.   button "No",22,204 75 22 10
  309. }
  310. on 1:dialog:QueryControlOptions2:init:0:{
  311.   did -i $dname 2 1 Apply | did -i $dname 2 2 QuietOpen | did -i $dname 2 3 QuietClose | did -i $dname 2 4 Random
  312.   did -c $dname 2 %OkButton
  313. }
  314. on *:dialog:QueryControlOptions2:sclick:*:{
  315.   if ($did == 10) set %QueryControl on
  316.   if ($did == 11) set %QueryControl off
  317.   if ($did == 12) { dialog -x $dname | dialog -m QueryControlLogs QueryControlLogs }
  318.   if ($did == 13) { dialog -x $dname | dialog -m QueryControlOptions QueryControlOptions }
  319.   if ($did == 14) { did -r $dname 4,6,8 }
  320.   if ($did == 15) { set %AutoRejectReason Automatically rejected due to inactivity | set %RejectReason Generic rejection message | set %OnOpen You have activated my Query Control $+ $chr(44) please wait for a response. | dialog -x $dname | dialog -m QueryControlOptions2 QueryControlOptions2 }
  321.   if ($did == 16) { did -b $dname 16 | dialog -m QueryControlHelp QueryControlHelp }
  322.   if ($did == 17) { did -b $dname 17 | dialog -m QueryControlAbout QueryControlAbout }
  323.   if ($did == 18) { set %OkButton $did(1) | set %AutoRejectReason $did(4) | set %RejectReason $did(6) | set %OnOpen $did(8) | dialog -x $dname }
  324.   if ($did == 21) { set %NotifyOtherPM 1 }
  325.   if ($did == 22) { set %NotifyOtherPM 0 }
  326. }
  327. dialog QueryControlHelp {
  328.   showrecent
  329.   title "AV2 Query Control Options Help"
  330.   size -1 -1 200 50
  331.   option dbu
  332.   text "Enable/Disable: Enable and disable the entire query control.",1,7 5 200 10
  333.   text "Logs/Setup: Opens either the logs dialog or the initial on-open dialog.",2,7 12 200 10
  334.   text "Clear/Defult: Clears all text fields, or sets them to the default values.",3,7 19 200 10
  335.   text "Help/About: Gives help about the buttons, or info about the query control.",4,7 26 200 10
  336.   button "Close",5,80 35 25 10
  337. }
  338. on *:dialog:QueryControlHelp:sclick:*:{
  339.   if ($did == 5) { dialog -x $dname | did -e QueryControlOptions2 16 }
  340. }
  341. dialog QueryControlAbout {
  342.   showrecent
  343.   title "About AV2 Query Control"
  344.   size -1 -1 130 50
  345.   option dbu
  346.   text "Created: Saturday, July 18, 2009. 13:01:56.",1,7 5 200 10
  347.   text "Author: Sky, Adorable, and Aries.",2,7 12 200 10
  348.   text "Server: Rizon.  /Server irc.Rizon.net -j #Mafia.",3,7 19 200 10
  349.   text "Version: 0.63.2786.5",4,7 26 200 10
  350.   button "Close",5,50 35 25 10
  351. }
  352. on *:dialog:QueryControlAbout:sclick:*:{
  353.   if ($did == 5) { dialog -x $dname | did -e QueryControlOptions2 17 }
  354. }
  355. alias WriteNextIni {
  356.   set %x 1
  357.   while ($ini(QueryControl.ini,$2,%x)) {
  358.     if (!$readini(QueryControl.ini,$2,%x)) { writeini -n $1 $2 %x $3- | return }
  359.     inc %x
  360.   }
  361.   writeini -n $1 $2 %x $3-
  362. }
  363. alias RemoveFromList2 {
  364.   set %x 1
  365.   while (%x <= %highest)) {
  366.     if ($readini(QueryControl.ini,Message,%x)) == $1) { remini QueryControl.ini | return }
  367.     inc %x
  368.   }
  369. }
  370. dialog QueryControlLogs {
  371.   showrecent
  372.   title "AV2 Query Control Full Logs"
  373.   size -1 -1 220 180
  374.   option dbu
  375.   text "Full logs",111,95 1 20 10
  376.   box "",2,1 5 217 140
  377.   combo 3,5 11 210 135, autohs
  378.   button "Delete",7,50 149 31 12
  379.   button "Ok",10,10 165 25 10,cancel
  380.   button "Options"11,95 165 25 10
  381.   button "Cancel",12,185 165 25 10,cancel
  382.   button "Clear",13,140 149 31 12
  383. }
  384. on 1:dialog:QueryControlLogs:init:0:{
  385.   set %x 1
  386.   set %y 1
  387.   while ($ini(QueryControl.ini,All,%x)) {
  388.     if ($readini(QueryControl.ini,All,%x) != $null) { did -i QueryControlLogs 3 %y $readini(QueryControl.ini,All,%x) }
  389.     inc %x
  390.   }
  391. }
  392. on *:dialog:QueryControlLogs:sclick:*:{
  393.   if ($did == 7) {
  394.     if ($did(3) == $null) { set %AMSGError No message specified to delete from the logs. | ShowError | return }
  395.     if ($InList(All,$did(3)) == no) { set %AMSGError That message does not appear to be in the log list. | ShowError | return }
  396.     RemoveFromList All $did(3)
  397.     did -r QueryControlLogs 3
  398.     dialog -x QueryControlLogs
  399.     dialog -m QueryControlLogs QueryControlLogs
  400.   }
  401.   if ($did == 11) { dialog -x QueryControlLogs | QueryControl }
  402.   if ($did == 13) { .remove QueryControl.ini | dialog -x QueryControlLogs | dialog -m QueryControlLogs QueryControlLogs }
  403. }
  404. alias QueryControl dialog -m QueryControlOptions2 QueryControlOptions2
Add Comment
Please, Sign In to add comment