Skip to content

Commit 1347def

Browse files
committed
Small changes.
1 parent a5e5a70 commit 1347def

File tree

6 files changed

+14
-18
lines changed

6 files changed

+14
-18
lines changed

Memory/NodeDissector.cs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,6 @@ public static Type GuessType(BaseHexNode node, MemoryBuffer memory)
6464
#endif
6565
}
6666

67-
if (is4ByteAligned)
6867
{
6968
#if WIN32
7069
var pointerType = GuessPointerType(data32.IntPtr, memory);

Nodes/BaseMatrixNode.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ protected int DrawMatrixType(ViewInfo view, int x, int y, string type, DrawMatri
4141

4242
x += view.Font.Width;
4343

44-
x = AddComment(view, x, y);
44+
AddComment(view, x, y);
4545

4646
if (levelsOpen[view.Level])
4747
{

Program.cs

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,14 @@ static void Main()
2727
{
2828
DesignMode = false; // The designer doesn't call Main()
2929

30-
DpiUtil.ConfigureProcess();
30+
try
31+
{
32+
DpiUtil.ConfigureProcess();
33+
}
34+
catch
35+
{
36+
37+
}
3138

3239
NativeMethods.EnableDebugPrivileges();
3340

UI/BannerBox.cs

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -74,14 +74,11 @@ private void UpdateBanner()
7474

7575
image = BannerFactory.CreateBanner(Width, DefaultBannerHeight, icon, title, text, true);
7676

77-
if (oldImage != null)
78-
{
79-
oldImage.Dispose();
80-
}
77+
oldImage?.Dispose();
8178

8279
Invalidate();
8380
}
84-
catch (Exception)
81+
catch
8582
{
8683

8784
}

UI/DpiUtil.cs

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -68,14 +68,7 @@ private static void EnsureInitialized()
6868

6969
public static void ConfigureProcess()
7070
{
71-
try
72-
{
73-
NativeMethods.SetProcessDpiAwareness();
74-
}
75-
catch
76-
{
77-
78-
}
71+
NativeMethods.SetProcessDpiAwareness();
7972
}
8073

8174
public static int ScaleIntX(int i)

UI/MemoryPreviewToolTip.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -57,8 +57,8 @@ public MemoryPreviewToolTip()
5757
Classes = new List<ClassNode>()
5858
};
5959

60-
Popup += new PopupEventHandler(OnPopup);
61-
Draw += new DrawToolTipEventHandler(OnDraw);
60+
Popup += OnPopup;
61+
Draw += OnDraw;
6262
}
6363

6464
private void OnPopup(object sender, PopupEventArgs e)

0 commit comments

Comments
 (0)