[script]
n0=menu status,channel,query {
n1=  -
n2=  Hash Tabloları: dialog $iif(!$dialog(hash_table),-m hash_table,-v) hash_table
n3=}
n4=dialog hash_table {
n5=  title "Hash Tablo Görüntüleyici/Düzenleyici"
n6=  size -1 -1 245 165
n7=  option dbu
n8=  box "Tablolar:", 1, 5 5 75 110
n9=  list 4, 10 15 65 85, size extsel hsbar
n10=  button "Seçilenleri Sil", 16, 25 102 35 10
n11=  box "Parçalar:", 2, 85 5 75 110
n12=  list 5, 90 15 65 85, size extsel hsbar
n13=  button "Seçilenleri Sil", 17, 105 102 35 10
n14=  box "Veriler:", 3, 165 5 75 110
n15=  list 6, 170 15 65 85, size extsel hsbar
n16=  button "Seçilenleri Sil", 18, 185 102 35 10
n17=  box "", 7, 5 115 235 45
n18=  text - Düzenlemeyi istediğiniz değere listeden çift tıklayın. $crlf $+ - Bağımsız eklemek için 'Temizle' butonuna basın., 8, 10 142 180 14, disable
n19=  text "Tablo:", 9, 11 122 25 8
n20=  edit "", 12, 10 130 60 10, autohs
n21=  text "Parça:", 10, 71 122 25 8
n22=  edit "", 13, 70 130 60 10, autohs
n23=  text "Veri:", 11, 131 122 25 8
n24=  edit "", 14, 130 130 60 10, autohs
n25=  button "Ekle/Düzenle", 15, 195 125 40 12
n26=  button "Temizle", 20, 195 141 40 12
n27=}
n28=alias -l hash_tablo { did -r hash_table 4,5,6 | var %x = 1 | while $hget(%x) { did -az hash_table 4 $hget(%x) | inc %x } | hash_parça $1 $2 }
n29=alias -l hash_parça { 
n30=  did -r hash_table 5,6
n31=  if $1 { var %y = 1 | while $hget(%y) { if $hget(%y) == $1 { set %hash1 %y | break } | else inc %y } }
n32=  var %x = 1 | while $hget(%hash1,%x).item { 
n33=    did -az hash_table 5 $hget(%hash1,%x).item
n34=    did -az hash_table 6 $hget(%hash1,%x).data
n35=    inc %x
n36=  }
n37=  $iif($2,did -c hash_table 4 $didwm(hash_table,4,$2)) | unset %hash1
n38=}
n39=on *:dialog:hash_table:init:*:hash_tablo 
n40=on *:dialog:hash_table:sclick:4:hash_parça $did(4,$did(4).sel)
n41=on *:dialog:hash_table:sclick:5:{ 
n42=  did -u $dname 6
n43=  if $did(6,0).lines != 0 { var %x = 1 | while $did(5,%x).sel { did -ck $dname 6 $did(5,%x).sel | inc %x } }
n44=}
n45=on *:dialog:hash_table:sclick:6:{ did -c $dname 5 $did(6).sel }
n46=on *:dialog:hash_table:dclick:4:{ 
n47=  did -re $dname 12,13,14
n48=  did -u $dname 5,6
n49=  did -a $dname 12 $did(4,$did(4).sel)
n50=  did -b $dname 13,14
n51=}
n52=on *:dialog:hash_table:dclick:5:{ 
n53=  did -re $dname 12,13,14
n54=  did -u $dname 6
n55=  did -a $dname 12 $did(4,$did(4).sel)
n56=  did -a $dname 13 $did(5,$did(5).sel) 
n57=  did -b $dname 12,14
n58=}
n59=on *:dialog:hash_table:dclick:6:{ 
n60=  did -re $dname 12,13,14
n61=  did -ab $dname 12 $did(4,$did(4).sel)
n62=  did -ab $dname 13 $did(5,$did(5).sel) 
n63=  did -a $dname 14 $did(6,$did(6).sel) 
n64=}
n65=
n66=on *:dialog:hash_table:sclick:16-18:{
n67=  if $did == 16 { var %x = 1 | while $did(4,$did(4,%x).sel) { .hfree $did(4,$did(4,%x).sel) | inc %x } | hash_tablo }
n68=  if $did == 17 { var %x = 1 | while $did(5,%x).sel { .hdel $did(4,$did(4).sel).text $did(5,$did(5,%x).sel) | inc %x }
n69=  hash_parça $did(4,$did(4).sel).text $did(4,$did(4).sel).text }
n70=  if $did == 18 { var %x = 1 | while $did(6,%x).sel { .hadd $did(4,$did(4).sel).text $did(5,$did(6,%x).sel) | inc %x } 
n71=  hash_parça $did(4,$did(4).sel).text $did(4,$did(4).sel).text }
n72=}
n73=on *:dialog:hash_table:sclick:15:{
n74=  if $did(12).enabled && $did(13).enabled && $did(14).enabled { 
n75=    var %q = 1 | while $hget(%q) { 
n76=    if $hget(%q) == $did(12) { $iif($did(13),.hadd $did(12) $did(13) $iif($did(14),$did(14))) | set -u %hash2 1 | break } | else inc %q }
n77=    if !%h { .hmake $did(12) $iif($did(13), $did(13) $iif($did(14), $did(14))) }
n78=    hash_tablo $did(12) $did(12) | did -re $dname 12,13,14
n79=  }
n80=  if (!$did(13).enabled && !$did(14).enabled) {
n81=    if $did(4,$did(4).sel) { var %e = 1 | while $hget(%e) { if $hget(%e) == $did(4,$did(4).sel) { set -u2 %hash3 %e | break } | else inc %e } }
n82=    var %x = 1 | while $hget(%hash3,%x).item {
n83=      .hadd -m $did(12) $hget(%hash3,%x).item $hget(%hash3,%x).data
n84=      inc %x
n85=    }
n86=    .hfree $did(4,$did(4).sel) | hash_tablo $did(12) $did(12) | did -re $dname 12,13,14
n87=  }
n88=  if (!$did(12).enabled && !$did(14).enabled) { .hadd -m $did(12) $did(13) | hash_parça $did(12) $did(12) | did -re $dname 12,13,14 }
n89=  if (!$did(12).enabled && !$did(13).enabled) { .hadd -m $did(12) $did(13) $did(14) | hash_parça $did(12) $did(12) | did -re $dname 12,13,14 }
n90=}
n91=on *:dialog:hash_table:sclick:20:{ did -u $dname 4,5,6 | did -re $dname 12,13,14 | hash_tablo }
