Yüksek öğretim okumadım. Ancak çevremdeki okuyanlardan gördüğüm kadarıyla onlarda da gösterilmemiş gibi geliyor.
Bu konu kullanıcı deneyimi açısından çok ama çok ciddi bir konu. Bana kalırsa yazılımın en önemli konusudur. (Önemlilerinden değil direkt en önemlisi.)
Neden bilmiyorum ama 4 yıl boyunca orta öğretimde yazılım bölümünde asenkron programlama gösterilmedi ve gösterilmemesinden bir yana yapılan Türk uygulamalarının çoğu da asenkron çalışmıyor. Özellikle en çok dikkatimi çekenler ise BTK ve DEVLET gibi büyük sitelerde dahil olmak üzere:
Hastane otomasyonları, (Sıra alma, tc girme vb.) Okul uygulamaları, MEB, EBYS, AKIS ve bunların kurulum araçları. Gerçekten böyle ciddi uygulamaları yaparken nasıl hiç modern teknolojilerden ve bu tür ciddi konulardan mahrum bırakıyorlar bu yazılımları anlamıyorum. Yani uygulamalar, siteler vs. o kadar itici geliyor ki anlatamam. Nasıl böyle olabiliyor diye sorguluyorum. Hele özellikle yapılan yazılımın arkada bir işlem yaparken bilgisayarın ve uygulamanın donması gerçekten çok can sıkıcı.
Sene olmuş 2025 gerçekten hâla Win7 ve WinForm kullanıyoruz ve Öğretiyoruz. Meb 20 yıl önceki teknolojiyi öğretiyor. Hatta bunlardan sonra Bunu görünce duygulandım ama bakınca da beklediğim içerikleri alamadım. Bildiğimiz AI'den alınıp yapıştırılmış gibi geldi.
Tamam da nedir bu kadar şikayetçi olduğun?
Ben ve benim gibi yazılımdan çıkan insanların temelini böyle:
Burdaki kodlar benim yaklaşık 2 yıl önceki projemin (Windoc) WinForm ile yapılmış ve sadece BTK akademi ve MEB'in öğrettikleriyle yapmış hâlim. Üstüne üstlük burası öğrendiklerimin daha düzgün ve optimal hâli. Evet kod berbat biliyorum ancak konu bu değil. Temel doğru atılmadıkça bu ve benzer berbatlıkları önümüzdeki çoğu gencin yapacağını düşünüyorum. Baştan itibaren bu optimizasyon ve performans konularına değinilmesi gerektiğini düşünüyorum. Biliyorum bu biraz öğrencileri bunaltabilir ama zaten yazılım bölümü isteksiz yapılmaz yani çekilemez ki. Geçen sene WinUI 3'e geçmeye karar vermiştim. Hem WinUI 3 öğreniyordum hem de optimizasyon konusunu. Bazen geriye dönüp kodlarıma bakıyorum da ne kadar saçma yazmışım böyle diye. Neden acaba biz her konuda diğer ülkelere kıyasla çok geriden geliyoruz diye soruyorum. Bakın kesinlikle ülkeyi kötülemiyorum beni yanlış anlamayın. Ama nasıl diyeyim. Yani bir tuhaflık var. Birisi bir şey yapmak ister bütün türkler "Yav onu nasıl yapacaksın" vb saçma saçma cümlelerle yapmak isteyen kişinin moralini bozar. Durduk yere sorun çıkaran tipler. Öfke kontrolü olmayan insanlar. Saçma saçma gündemler. Kadına şiddet, Cinsiyetçilik, Irkçılık ve bunları övmek vb. Gerçekten gelişemiyoruz ya.
Bu kadar okuyamam ben diyenler için veya üstteki yazdıklarımı anlamayanlar için özet:
Bir yıl önce WinUI 3 ve Optimizasyon konularını öğrenmeye başlamıştım ancak temel kötü olduğundan:
Böyle olması gereken kod, böyle oluyor:
Aralarında mikro farklar varmış gibi görünmesine aldanmayın. Bu ve benzeri ufak hâtalar büyük projelerde çok ciddi sorun olabilir. Bunlardan yola çıkarak, yeni teklojinin ve yeni konuların ülkemizde de görülmesini umarım ve sizlerinde yorumlarınızı beklerim
Bu konu kullanıcı deneyimi açısından çok ama çok ciddi bir konu. Bana kalırsa yazılımın en önemli konusudur. (Önemlilerinden değil direkt en önemlisi.)
Neden bilmiyorum ama 4 yıl boyunca orta öğretimde yazılım bölümünde asenkron programlama gösterilmedi ve gösterilmemesinden bir yana yapılan Türk uygulamalarının çoğu da asenkron çalışmıyor. Özellikle en çok dikkatimi çekenler ise BTK ve DEVLET gibi büyük sitelerde dahil olmak üzere:
Hastane otomasyonları, (Sıra alma, tc girme vb.) Okul uygulamaları, MEB, EBYS, AKIS ve bunların kurulum araçları. Gerçekten böyle ciddi uygulamaları yaparken nasıl hiç modern teknolojilerden ve bu tür ciddi konulardan mahrum bırakıyorlar bu yazılımları anlamıyorum. Yani uygulamalar, siteler vs. o kadar itici geliyor ki anlatamam. Nasıl böyle olabiliyor diye sorguluyorum. Hele özellikle yapılan yazılımın arkada bir işlem yaparken bilgisayarın ve uygulamanın donması gerçekten çok can sıkıcı.
Sene olmuş 2025 gerçekten hâla Win7 ve WinForm kullanıyoruz ve Öğretiyoruz. Meb 20 yıl önceki teknolojiyi öğretiyor. Hatta bunlardan sonra Bunu görünce duygulandım ama bakınca da beklediğim içerikleri alamadım. Bildiğimiz AI'den alınıp yapıştırılmış gibi geldi.
Tamam da nedir bu kadar şikayetçi olduğun?
Ben ve benim gibi yazılımdan çıkan insanların temelini böyle:
C#:
if (tbWindocTurkish.Checked)
{
infoMessage.AppendLine("Bilgisayar adı : " + computerName);
infoMessage.AppendLine("Kullanıcı adı : " + userName);
infoMessage.AppendLine("Bilgisayar bit : " + computerBitText + ", " + processorCore + " çekirdekli işlemci");
infoMessage.AppendLine("İşletim sistemi : " + windowsEdition);
infoMessage.AppendLine("İşletim sistemi : " + OS);
infoMessage.AppendLine(ipInformation);
for (int i = 0; i <= Math.Min((int)diskIndex, 9); i++) { infoMessage.AppendLine($"{diskName[i]} Toplam boyut : {diskSpace[i]} GB - Kalan boyut : {diskRemain[i]} GB"); }
infoMessage.AppendLine("\nDaha ayrıntılı bilgi almak ister misiniz?");
if (MessageBox.Show(infoMessage.ToString(), "Sistem bilgileri", MessageBoxButtons.YesNo, MessageBoxIcon.Information) == DialogResult.Yes) { Process.Start("dxdiag.exe"); }
}
else
{
infoMessage.AppendLine("Computer name : " + computerName);
infoMessage.AppendLine("User name : " + userName);
infoMessage.AppendLine("Computer bit : " + computerBitText + ", " + processorCore + " core processor");
infoMessage.AppendLine("Operating system : " + windowsEdition);
infoMessage.AppendLine("Operating system : " + OS);
infoMessage.AppendLine(ipInformation);
for (int i = 0; i <= Math.Min((int)diskIndex, 9); i++) { infoMessage.AppendLine($"{diskName[i]} Total size : {diskSpace[i]} GB - Remaining size : {diskRemain[i]} GB"); }
infoMessage.AppendLine("\nWould you like to get more detailed information?");
if (MessageBox.Show(infoMessage.ToString(), "System info", MessageBoxButtons.YesNo, MessageBoxIcon.Information) == DialogResult.Yes) { Process.Start("dxdiag.exe"); }
}
Kod:
private void iBtnUpdate_Click(object sender, EventArgs e)
{
if (txtUpdate.Text.Length >= 1 && txtUpdate.Text.Length <= 20)
{
update = txtUpdate.Text;
string update2 = update;
Process process = new Process();
ProcessStartInfo startInfo = new ProcessStartInfo();
startInfo.WindowStyle = ProcessWindowStyle.Hidden;
startInfo.FileName = "cmd.exe";
process.StartInfo.Verb = "runas";
process.StartInfo = startInfo;
if (computer) { update = update.Replace('ö', 'o').Replace('ü', 'u').Replace('ğ', 'g').Replace('ş', 's').Replace('ı', 'i').Replace('ç', 'c').Replace('Ö', 'O').Replace('Ü', 'U').Replace('Ğ', 'G').Replace('Ş', 'S').Replace('İ', 'I').Replace('Ç', 'C'); update2 = update.Replace('ö', 'o').Replace('ü', 'u').Replace('ğ', 'g').Replace('ş', 's').Replace('ı', 'i').Replace('ç', 'c').ToUpper().Replace('Ö', 'O').Replace('Ü', 'U').Replace('Ğ', 'G').Replace('Ş', 'S').Replace('İ', 'I').Replace('Ç', 'C'); }
if (computer && update2 != computerName && txtUpdate.Text.Length >= 1 && txtUpdate.Text.Length <= 15)
{
if ((tbWindocTurkish.Checked && MessageBox.Show("Kabul ederseniz bilgisayar yeniden başlar ve bilgisayar adınız \"" + update + "\" olarak değişicektir!\n\nDevam etmek istiyormusunuz?", "Uyarı!", MessageBoxButtons.YesNo, MessageBoxIcon.Warning) == DialogResult.Yes) || (!tbWindocTurkish.Checked && MessageBox.Show("If you accept, the computer will restart and your computer name will be changed to \"" + update + "\"\n\nDo you want to continue?", "Warning!", MessageBoxButtons.YesNo, MessageBoxIcon.Warning) == DialogResult.Yes))
{
try
{
startInfo.Arguments = "/c WMIC computersystem where caption=\"%computername%\" rename \"" + update + "\"" + "&" + "shutdown -f -r -t 0";
process.Start();
process.WaitForExit();
if ((tbWindocTurkish.Checked && MessageBox.Show("Değişikliklerin uygulanabilmesi için bilgisayarınız yeniden başlamalı.\nYeniden başlatmak istiyor musunuz?", "Devam etmek istiyormusunuz?", MessageBoxButtons.YesNo, MessageBoxIcon.Question) == DialogResult.Yes) || (!tbWindocTurkish.Checked && MessageBox.Show("Your computer must restart for the changes to be applied.\nDo you want to restart?", "Do you want to continue?", MessageBoxButtons.YesNo, MessageBoxIcon.Question) == DialogResult.Yes))
{
startInfo.Arguments = "/c shutdown -f -r -t 0";
process.Start();
process.WaitForExit();
}
}
catch { }
}
else
if (tbWindocTurkish.Checked)
MessageBox.Show("İşlem iptal edildi", "Bilgilendirme", MessageBoxButtons.OK, MessageBoxIcon.Information);
else
MessageBox.Show("Transaction cancelled", "Notification", MessageBoxButtons.OK, MessageBoxIcon.Information);
}
else if (user && txtUpdate.Text != userName && txtUpdate.Text.Length >= 1 && txtUpdate.Text.Length <= 20)
{
if ((tbWindocTurkish.Checked && MessageBox.Show("Kabul ederseniz bilgisayar yeniden başlar ve kullanıcı adınız \"" + update + "\" olarak değişicektir!\n\nDevam etmek istiyormusunuz?", "Uyarı!", MessageBoxButtons.YesNo, MessageBoxIcon.Warning) == DialogResult.Yes) || (!tbWindocTurkish.Checked && MessageBox.Show("If you accept, the computer will restart and your user name will be changed to \"" + update + "\"\n\nDo you want to continue?", "Warning!", MessageBoxButtons.YesNo, MessageBoxIcon.Warning) == DialogResult.Yes))
{
try
{
startInfo.Arguments = "/c" + "wmic useraccount where name='" + userName + "' rename " + txtUpdate.Text;
process.Start();
process.WaitForExit();
if ((tbWindocTurkish.Checked && MessageBox.Show("Değişikliklerin uygulanabilmesi için bilgisayarınız yeniden başlamalı.\nYeniden başlatmak istiyor musunuz?", "Devam etmek istiyormusunuz?", MessageBoxButtons.YesNo, MessageBoxIcon.Question) == DialogResult.Yes) || (!tbWindocTurkish.Checked && MessageBox.Show("Your computer must restart for the changes to be applied.\nDo you want to restart?", "Do you want to continue?", MessageBoxButtons.YesNo, MessageBoxIcon.Question) == DialogResult.Yes))
{
startInfo.Arguments = "/c shutdown -f -r -t 0";
process.Start();
process.WaitForExit();
}
}
catch { }
}
else
if (tbWindocTurkish.Checked)
MessageBox.Show("İşlem iptal edildi", "Bilgilendirme", MessageBoxButtons.OK, MessageBoxIcon.Information);
else
MessageBox.Show("Transaction cancelled", "Notification", MessageBoxButtons.OK, MessageBoxIcon.Information);
}
else if ((user && txtUpdate.Text == userName) || (computer && update2 == computerName))
if (tbWindocTurkish.Checked)
MessageBox.Show("Aynı ad olmamalı!", "Hata ile karşılaştık!", MessageBoxButtons.OK, MessageBoxIcon.Warning);
else
MessageBox.Show("Must not be the same name!", "We encountered an error!", MessageBoxButtons.OK, MessageBoxIcon.Warning);
else
if (tbWindocTurkish.Checked)
MessageBox.Show("Adı doğru yazınız!", "Hata ile karşılaştık!", MessageBoxButtons.OK, MessageBoxIcon.Warning);
else
MessageBox.Show("Please write the name correctly!", "We encountered an error!", MessageBoxButtons.OK, MessageBoxIcon.Warning);
}
txtUpdate.ReadOnly = true;
txtUpdate.Visible = false;
txtUpdate.Enabled = false;
iBtnUpdate.Visible = false;
iBtnUpdate.Enabled = false;
txtUpdate.Text = "Y";
txtUpdate.ForeColor = Color.Gray;
txtUpdate.Font = new Font("Times New Roman", 8, FontStyle.Italic);
computer = false; user = false;
}
C#:
private void iBtnSearch_Click(object sender, EventArgs e)
{
if ((tbWindocTurkish.Checked && MessageBox.Show("Çerezleri ve kalıntıları silmeniz için size birkaç dosya açacağım hepsini kontrol edin.\n\nDevam edelim mi?", "Hazır mısınız?", MessageBoxButtons.YesNo, MessageBoxIcon.Question) == DialogResult.Yes) || (!tbWindocTurkish.Checked && MessageBox.Show("I will open a few files for you to delete cookies and residues, check them all.\n\nShall we continue?", "Are you ready?", MessageBoxButtons.YesNo, MessageBoxIcon.Question) == DialogResult.Yes))
{
DiskInfo();
Process process = new Process();
ProcessStartInfo startInfo = new ProcessStartInfo();
startInfo.FileName = "explorer.exe";
startInfo.Verb = "runas";
try
{
startInfo.Arguments = Path.GetPathRoot(Environment.SystemDirectory) + @"Windows\Temp";
if (Directory.Exists(startInfo.Arguments))
{
process.StartInfo = startInfo;
process.Start();
}
startInfo.Arguments = Environment.GetFolderPath(Environment.SpecialFolder.MyDocuments);
if (Directory.Exists(startInfo.Arguments))
{
process.StartInfo = startInfo;
process.Start();
}
for (int i = 0; i <= diskIndex; i++)
{
try
{
startInfo.Arguments = diskName[i] + @"Program Files (x86)";
if (Directory.Exists(startInfo.Arguments))
{
process.StartInfo = startInfo;
process.Start();
}
startInfo.Arguments = diskName[i] + @"ProgramData";
if (Directory.Exists(startInfo.Arguments))
{
process.StartInfo = startInfo;
process.Start();
}
startInfo.Arguments = diskName[i] + @"Users\" + userName + @"\AppData";
if (Directory.Exists(startInfo.Arguments))
{
process.StartInfo = startInfo;
process.Start();
}
startInfo.Arguments = diskName[i] + @"Program Files (x86)\Temp";
if (Directory.Exists(startInfo.Arguments))
{
process.StartInfo = startInfo;
process.Start();
}
startInfo.Arguments = diskName[i] + @"Users\" + userName + @"\AppData\Local\Temp";
if (Directory.Exists(startInfo.Arguments))
{
process.StartInfo = startInfo;
process.Start();
}
startInfo.Arguments = diskName[i] + @"Users\" + userName + @"\AppDataoaming\Microsoft\Windows\Start Menu\Programs";
if (Directory.Exists(startInfo.Arguments))
{
process.StartInfo = startInfo;
process.Start();
}
}
catch { }
}
}
catch { }
}
}
C#:
private void iBtnRepair_Click(object sender, EventArgs e)
{
TopMost = false; timerControl = false;
DialogResult dialogResult;
if (tbWindocTurkish.Checked)
dialogResult = MessageBox.Show("İleri seviye tarama yapmadan önce normal taramalar yapılır. ARDINDAN SİZE SON KEZ SORULUR VE BİLGİSAYAR KAPANIR İLERİ SEVİYE TARAMA BAŞLAR. SON KEZ ONAYLAMAK İÇİN: Açılan konsol ekranına \"Y\" ardından \"ENTER\" tuşuna basın!\nBU İŞLEM UZUN SÜREBİLİR VE KAPATILMAMALIDIR!\n\nBilmiyorsanız YouTube kanalımda Windoc ile ilgili olan videonun adımlarını takip edin!\n\nNOT: Normal veya İleri seviye farketmeksizin tarama bitmeden uygulamayı veya bilgisayarı kapatmak risklidir!\n\nİleri seviye tarama yapalım mı? (Hayır derseniz, sadece normal taramalar yapılır.)", "Tarama derecesi", MessageBoxButtons.YesNoCancel, MessageBoxIcon.Question);
else
dialogResult = MessageBox.Show("Normal scans are performed before performing advanced scanning. THEN YOU WILL BE ASKED FOR THE LAST TIME AND THE COMPUTER SHUTS OFF AND ADVANCED SCANNING STARTS. TO CONFIRM FOR THE FINAL TIME: Press \"Y\" then \"ENTER\" on the console screen that opens!\nTHIS PROCESS MAY TAKE A LONG TIME AND SHOULD NOT BE CLOSED!\n\nIf you don't know, follow the steps of the video about Windoc on my YouTube channel!\n\nNOTE: Regardless of Normal or Advanced level, it is risky to close the application or the computer before the scan is finished!\n\nShall we do an Advanced scan? (If you say no, only normal scans will be performed.)", "Scan degree", MessageBoxButtons.YesNoCancel, MessageBoxIcon.Question);
if (dialogResult == DialogResult.Yes)
{
try
{
Process.Start("ms-settings:troubleshoot");
Process.Start("control.exe", "/name Microsoft.SecurityCenter");
Process.Start("msdt.exe", "/id DeviceDiagnostic");
Process.Start("msdt.exe", "/id IESecurityDiagnostic");
Process.Start("msdt.exe", "/id NetworkDiagnosticsWeb");
Process.Start("msdt.exe", "/id WindowsUpdateDiagnostic");
Process.Start("msdt.exe", "/id AudioPlaybackDiagnostic");
Process.Start("msdt.exe", "/id NetworkDiagnosticsInbound");
Process.Start("msdt.exe", "/id NetworkDiagnosticsFileShare");
Process.Start("msdt.exe", "/id NetworkDiagnosticsNetworkAdapter");
Process.Start("msdt.exe", "/id PCWDiagnostic");
Process.Start("msdt.exe", "/id PowerDiagnostic");
Process.Start("msdt.exe", "/id SearchDiagnostic");
Process.Start("msdt.exe", "/id PrinterDiagnostic");
Process.Start("msdt.exe", "/id MaintenanceDiagnostic");
Process.Start("msdt.exe", "/id AudioRecordingDiagnostic");
Process.Start("msdt.exe", "/id WindowsMediaPlayerDVDDiagnostic");
Process.Start("msdt.exe", "/id WindowsMediaPlayerLibraryDiagnostic");
Process.Start("msdt.exe", "/id WindowsMediaPlayerConfigurationDiagnostic");
Process process = new Process();
ProcessStartInfo startInfo = new ProcessStartInfo();
startInfo.FileName = "cmd.exe";
startInfo.Arguments = "/k color b & cls & ipconfig /release & cls & ipconfig /renew & cls & ipconfig / flushdns & cls & netsh advfirewall reset &repair - bde & cls & sfc / scannow & cls & dism.exe /online /Cleanup-Image /StartComponentCleanup /RestoreHealth & cls & dism.exe /online /cleanup-image /checkhealth & cls & dism.exe /online /cleanup-image /ScanHealth & cls & dism.exe /online /cleanup-image /restorehealth & cls & dism.exe /online /cleanup-image /restorehealth /source:WIM:X:\\Sources\\Install.wim:1 /limitaccess";
startInfo.Verb = "runas";
process.StartInfo = startInfo;
process.Start();
process.WaitForExit();
startInfo.Arguments = "/c chkdsk /f";
process.Start();
if ((tbWindocTurkish.Checked && MessageBox.Show("Şimdi yeniden başlatalım mı?", "İşlem başarılı!", MessageBoxButtons.OK, MessageBoxIcon.Question) == DialogResult.OK) || (!tbWindocTurkish.Checked && MessageBox.Show("Should we restart now?", "Operation successful!", MessageBoxButtons.OK, MessageBoxIcon.Question) == DialogResult.OK)) { startInfo.Arguments = "/c shutdown -f -r -t 0"; try { process.Start(); process.WaitForExit(); } catch { } }
}
catch { }
}
else if (dialogResult == DialogResult.No)
{
try
{
Process.Start("ms-settings:troubleshoot");
Process.Start("control.exe", "/name Microsoft.SecurityCenter");
Process.Start("msdt.exe", "/id DeviceDiagnostic");
Process.Start("msdt.exe", "/id IESecurityDiagnostic");
Process.Start("msdt.exe", "/id NetworkDiagnosticsWeb");
Process.Start("msdt.exe", "/id WindowsUpdateDiagnostic");
Process.Start("msdt.exe", "/id AudioPlaybackDiagnostic");
Process.Start("msdt.exe", "/id NetworkDiagnosticsInbound");
Process.Start("msdt.exe", "/id NetworkDiagnosticsFileShare");
Process.Start("msdt.exe", "/id NetworkDiagnosticsNetworkAdapter");
Process.Start("msdt.exe", "/id PCWDiagnostic");
Process.Start("msdt.exe", "/id PowerDiagnostic");
Process.Start("msdt.exe", "/id SearchDiagnostic");
Process.Start("msdt.exe", "/id PrinterDiagnostic");
Process.Start("msdt.exe", "/id MaintenanceDiagnostic");
Process.Start("msdt.exe", "/id AudioRecordingDiagnostic");
Process.Start("msdt.exe", "/id WindowsMediaPlayerDVDDiagnostic");
Process.Start("msdt.exe", "/id WindowsMediaPlayerLibraryDiagnostic");
Process.Start("msdt.exe", "/id WindowsMediaPlayerConfigurationDiagnostic");
Process process = new Process();
ProcessStartInfo startInfo = new ProcessStartInfo();
startInfo.FileName = "cmd.exe";
startInfo.Arguments = "/c color b & cls & ipconfig /release & cls & ipconfig /renew & cls & ipconfig / flushdns & cls & netsh advfirewall reset &repair - bde & cls & sfc / scannow & cls & dism.exe /online /Cleanup-Image /StartComponentCleanup /RestoreHealth & cls & dism.exe /online /cleanup-image /checkhealth & cls & dism.exe /online /cleanup-image /ScanHealth & cls & dism.exe /online /cleanup-image /restorehealth & cls & dism.exe /online /cleanup-image /restorehealth /source:WIM:X:\\Sources\\Install.wim:1 /limitaccess";
startInfo.Verb = "runas";
process.StartInfo = startInfo;
process.Start();
}
catch { }
}
if (dialogResult == DialogResult.Yes || dialogResult == DialogResult.No)
if (tbWindocTurkish.Checked)
MessageBox.Show("İşlem başarıyla tamamlandı!", "Başarılı!", MessageBoxButtons.OK, MessageBoxIcon.Question);
else
MessageBox.Show("The operation was completed successfully!", "Successful!", MessageBoxButtons.OK, MessageBoxIcon.Question);
if (databaseManager.database.UserSettings.TopMost)
TopMost = true;
timerControl = true;
}
private void iBtnMaximumPerformance_Click(object sender, EventArgs e)
{
if (pMaximumPerformance.Dock != DockStyle.Fill)
{
if (pSettings.Dock != DockStyle.Fill && pHelp.Dock != DockStyle.Fill && pMenu.Dock != DockStyle.Left)
databaseManager.database.UserSettings.ShowMenu = false;
else
databaseManager.database.UserSettings.ShowMenu = true;
iBtnHideMenu.PerformClick();
WindowState = FormWindowState.Minimized;
Enabled = false;
Visible = false;
cbUltraPerformance.SelectedIndex = 0;
pMaximumPerformance.Dock = DockStyle.Fill;
Enabled = true;
Visible = true;
iBtnRefresh.PerformClick();
lbSelected.Items.Add("-------------------------------------------------------------------------------------------");
lbSelected.Items.Add(" ");
lbSelected.Items.Add("-------------------------------------------------------------------------------------------");
lbSelected.Items.Add(" ");
if (tbWindocTurkish.Checked)
{
lbSelected.Items.Insert(0, " ↓ Maximum performans ↓ ");
lbSelected.Items.Insert(4, " ↓ Kapanmayacak uygulamalar ↓ ");
}
else
{
lbSelected.Items.Insert(0, " ↓ Maximum performance ↓ ");
lbSelected.Items.Insert(4, " ↓ Apps that won't close ↓ ");
cbPerformanceLevel.Items.Clear();
cbPerformanceLevel.Items.AddRange(new object[] {
"Realtime (Not recommend)",
"High (Recommend)",
"Above normal",
"Normal",
"Below normal",
"Idle"
});
cbUltraPerformance.Items.Clear();
cbUltraPerformance.Items.AddRange(new object[] {
"Not interfere",
"Below normal (may not be a problem)",
"Low(Risky!)"
});
}
iBtnMaximize.IconChar = FontAwesome.Sharp.IconChar.WindowMaximize;
if (tbWindocTurkish.Checked)
toolTip.SetToolTip(iBtnMaximize, "Tam ekran");
else
toolTip.SetToolTip(iBtnMaximize, "Full screen");
WindowState = FormWindowState.Normal;
}
else { btnExit.PerformClick(); }
}
Bu kadar okuyamam ben diyenler için veya üstteki yazdıklarımı anlamayanlar için özet:
Bir yıl önce WinUI 3 ve Optimizasyon konularını öğrenmeye başlamıştım ancak temel kötü olduğundan:
C#:
internal void ResponsiveSizeApply()
{
bool maximized = mainWindow.WindowState is WindowState.Maximized;
int size, top;
if (userSettings.TitleBarVisible)
{
top = 28;
size = maximized ? sizeInt32.Height - 40 : sizeInt32.Height - 32;
}
else
{
top = maximized ? -12 : -4;
size = sizeInt32.Height;
}
NavViewVertical.Margin = new Thickness(NavViewVertical.Margin.Left, top, NavViewVertical.Margin.Right, NavViewVertical.Margin.Bottom);
NavViewVertical.MinHeight = size;
}
C#:
public void ResponsiveSizeApply()
{
if (userSettings.TitleBarVisible)
{
NavViewVertical.MinHeight = mainWindow.WindowState is WindowState.Maximized ? sizeInt32.Height - 40 : sizeInt32.Height - 32;
NavViewVertical.Margin = new Thickness(NavViewVertical.Margin.Left, 28, NavViewVertical.Margin.Right, NavViewVertical.Margin.Bottom);
}
else
{
NavViewVertical.MinHeight = sizeInt32.Height;
NavViewVertical.Margin = mainWindow.WindowState is WindowState.Maximized
? new Thickness(NavViewVertical.Margin.Left, -12, NavViewVertical.Margin.Right, NavViewVertical.Margin.Bottom)
: new Thickness(NavViewVertical.Margin.Left, -4, NavViewVertical.Margin.Right, NavViewVertical.Margin.Bottom);
}
}