Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Release 2024.0.9 #188

Merged
merged 49 commits into from
Nov 20, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
49 commits
Select commit Hold shift + click to select a range
7962c5f
Main window refactoring
Nice3point Jul 1, 2023
8be21c3
Fix issue 180
Nice3point Jul 1, 2023
4a7b10a
CleanUp
Nice3point Jul 1, 2023
e110dc1
CleanUp
Nice3point Jul 1, 2023
db76776
Integrate Qodana Scan
Nice3point Jul 1, 2023
a5652d0
Update pipeline
Nice3point Jul 2, 2023
363effd
Update qodana
Nice3point Jul 2, 2023
1b2bab5
Nuke update
Nice3point Jul 3, 2023
d4a9030
Add qodana config
Nice3point Jul 3, 2023
ca5f225
Update menuitem style
Nice3point Jul 4, 2023
e97432d
Update Contributing.md
Nice3point Jul 4, 2023
e191d25
Fix modifiers
Nice3point Jul 4, 2023
eca3599
Update UI layout and boost performance
Nice3point Jul 4, 2023
f3f6de2
Restore border style consistency across UI components
Nice3point Jul 4, 2023
a91e0a4
Merge pull request #181 from jeremytammik/dev_gridmenu
Nice3point Jul 4, 2023
2519320
Simplify Content Overlay
Nice3point Jul 7, 2023
f6cd39c
Remove refresh awaiting
Nice3point Jul 7, 2023
e3b14c2
Enable group virtualization
Nice3point Jul 10, 2023
f147065
Apple group methods
Nice3point Jul 10, 2023
cfca963
Split builder
Nice3point Jul 10, 2023
8e7c003
Auto find context
Nice3point Jul 10, 2023
e036cdc
Update services
Nice3point Nov 14, 2023
5b05925
Update Readme.md
Nice3point Nov 14, 2023
ca364bf
Update dependencies
Nice3point Nov 14, 2023
55727dd
Merge remote-tracking branch 'origin/dev' into dev
Nice3point Nov 14, 2023
0fc01e7
Update qodana
Nice3point Nov 15, 2023
8e87c9f
Fluent lookup service
Nice3point Nov 15, 2023
5a07f46
Clean up
Nice3point Nov 15, 2023
a62a440
Merge UI library
Nice3point Nov 17, 2023
690e6db
Restore dialogs
Nice3point Nov 17, 2023
b5bdac5
Controls update
Nice3point Nov 18, 2023
865ae4b
Changed textBox border
Nice3point Nov 18, 2023
156bba3
SymbolIcon preview support
Nice3point Nov 18, 2023
02fba95
Update about view
Nice3point Nov 18, 2023
cb06296
ContentDialog restore height during resizing
Nice3point Nov 19, 2023
542f18e
Add missing ItemsPanel virtualization
Nice3point Nov 19, 2023
1781742
Dialog boundary
Nice3point Nov 19, 2023
ca77427
Disable selection restoring
Nice3point Nov 19, 2023
0cb771c
Fix revit unfocus during closeCurrentCommand
Nice3point Nov 19, 2023
c537b56
.Net 8 support
Nice3point Nov 19, 2023
c723533
GetBoundarySegments method of spatial elements support added
SergeyNefyodov Nov 19, 2023
a301d65
Issue 184
Nice3point Nov 19, 2023
8bdc905
Disable Qodana
Nice3point Nov 19, 2023
4a44ae0
Merge pull request #187 from SergeyNefyodov/dev-room-boundaries-feature
Nice3point Nov 19, 2023
95665da
Cleanup
Nice3point Nov 19, 2023
8a12d27
Fix R21 compability
Nice3point Nov 19, 2023
c46b60b
Update Changelog.md
Nice3point Nov 19, 2023
4a459b8
Fix wpfui #825
Nice3point Nov 19, 2023
876001b
Update Changelog.md
Nice3point Nov 19, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
13 changes: 6 additions & 7 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@

[*]
charset = utf-8
end_of_line = crlf
Expand Down Expand Up @@ -102,7 +101,7 @@ dotnet_naming_style.lower_camel_case_style_1.capitalization = camel_case
dotnet_naming_style.t_upper_camel_case_style.capitalization = pascal_case
dotnet_naming_style.t_upper_camel_case_style.required_prefix = T
dotnet_naming_style.upper_camel_case_style.capitalization = pascal_case
dotnet_naming_symbols.constants_symbols.applicable_accessibilities = public,internal,protected,protected_internal,private_protected
dotnet_naming_symbols.constants_symbols.applicable_accessibilities = public, internal, protected, protected_internal, private_protected
dotnet_naming_symbols.constants_symbols.applicable_kinds = field
dotnet_naming_symbols.constants_symbols.required_modifiers = const
dotnet_naming_symbols.event_symbols.applicable_accessibilities = *
Expand Down Expand Up @@ -130,16 +129,16 @@ dotnet_naming_symbols.private_static_fields_symbols.applicable_kinds = field
dotnet_naming_symbols.private_static_fields_symbols.required_modifiers = static
dotnet_naming_symbols.private_static_readonly_symbols.applicable_accessibilities = private
dotnet_naming_symbols.private_static_readonly_symbols.applicable_kinds = field
dotnet_naming_symbols.private_static_readonly_symbols.required_modifiers = static,readonly
dotnet_naming_symbols.private_static_readonly_symbols.required_modifiers = static, readonly
dotnet_naming_symbols.property_symbols.applicable_accessibilities = *
dotnet_naming_symbols.property_symbols.applicable_kinds = property
dotnet_naming_symbols.public_fields_symbols.applicable_accessibilities = public,internal,protected,protected_internal,private_protected
dotnet_naming_symbols.public_fields_symbols.applicable_accessibilities = public, internal, protected, protected_internal, private_protected
dotnet_naming_symbols.public_fields_symbols.applicable_kinds = field
dotnet_naming_symbols.static_readonly_symbols.applicable_accessibilities = public,internal,protected,protected_internal,private_protected
dotnet_naming_symbols.static_readonly_symbols.applicable_accessibilities = public, internal, protected, protected_internal, private_protected
dotnet_naming_symbols.static_readonly_symbols.applicable_kinds = field
dotnet_naming_symbols.static_readonly_symbols.required_modifiers = static,readonly
dotnet_naming_symbols.static_readonly_symbols.required_modifiers = static, readonly
dotnet_naming_symbols.types_and_namespaces_symbols.applicable_accessibilities = *
dotnet_naming_symbols.types_and_namespaces_symbols.applicable_kinds = namespace,class,struct,enum,delegate
dotnet_naming_symbols.types_and_namespaces_symbols.applicable_kinds = namespace, class, struct, enum, delegate
dotnet_naming_symbols.type_parameters_symbols.applicable_accessibilities = *
dotnet_naming_symbols.type_parameters_symbols.applicable_kinds = type_parameter
dotnet_separate_import_directive_groups = false
Expand Down
13 changes: 5 additions & 8 deletions .github/workflows/Workflow.yml → .github/workflows/Nuke.yml
Original file line number Diff line number Diff line change
@@ -1,19 +1,16 @@
name: Workflow

name: Nuke
on:
push:
branches:
- '**'
pull_request:
branches:
- '!master'
push:

jobs:
windows:
name: windows-2022
runs-on: windows-2022
steps:
- name: Checkout
uses: actions/checkout@v1
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Run Nuke Build
run: ./.nuke/build.cmd --GitHubToken ${{ secrets.GITHUB_TOKEN }}
2 changes: 1 addition & 1 deletion Benchmarks/Benchmarks.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,6 @@
<TargetFramework>net48</TargetFramework>
</PropertyGroup>
<ItemGroup>
<PackageReference Include="BenchmarkDotNet" Version="0.13.5" />
<PackageReference Include="BenchmarkDotNet" Version="0.13.*" />
</ItemGroup>
</Project>
10 changes: 5 additions & 5 deletions Build/Build.Configuration.cs
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ partial class Build
readonly AbsolutePath ArtifactsDirectory = RootDirectory / "output";
readonly AbsolutePath ChangeLogPath = RootDirectory / "Changelog.md";

protected override void OnBuildCreated()
protected override void OnBuildInitialized()
{
Configurations = new[]
{
Expand All @@ -20,10 +20,10 @@ protected override void OnBuildCreated()

VersionMap = new()
{
{"Release R21", "2021.2.8"},
{"Release R22", "2022.2.8"},
{"Release R23", "2023.2.8"},
{"Release R24", "2024.0.8"}
{"Release R21", "2021.2.9"},
{"Release R22", "2022.2.9"},
{"Release R23", "2023.2.9"},
{"Release R24", "2024.0.9"}
};
}
}
2 changes: 1 addition & 1 deletion Build/Build.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
<Platforms>AnyCPU</Platforms>
</PropertyGroup>
<ItemGroup>
<PackageReference Include="Nuke.Common" Version="7.0.0" />
<PackageReference Include="Nuke.Common" Version="7.0.6" />
</ItemGroup>
<ItemGroup>
<PackageDownload Include="GitVersion.Tool" Version="[5.12.0]" />
Expand Down
43 changes: 43 additions & 0 deletions Changelog.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,48 @@
# Changelog

# 2023-11-19 **2024.0.9**

## User interface

* **Settings Accessibility:** Most settings have been relocated to the grid context menu for a more intuitive and accessible user experience. Now, users can conveniently access and modify settings directly from the grid context menu

![image](https://github.com/jeremytammik/RevitLookup/assets/20504884/77fc172a-48d3-4439-a5d6-9d8d80ee0efc)

## Improvements

* Added ExtensibleStorage `Array` and `Map` support https://github.com/jeremytammik/RevitLookup/issues/184
* Added `Room.GetBoundarySegments()` support https://github.com/jeremytammik/RevitLookup/pull/187
* Added `BoundarySegment` support https://github.com/jeremytammik/RevitLookup/pull/187
* Added changing theme in runtime
* Optimized rendering performance for both tree and grid views, resulting in smoother and faster visual representation
* Added shortcuts for close current and all RevitLookup instances https://github.com/jeremytammik/RevitLookup/issues/172

* `Esc` now closes the current window.

* `Shift + Esc` closes all RevitLookup instances

* Explore all available shortcuts [here](https://github.com/jeremytammik/RevitLookup/wiki/Context-actions)

## Bugs

* Fixed some crashes https://github.com/jeremytammik/RevitLookup/issues/180

## Breaking changes

* Disabled the last selection restoration during search to improve performance, especially on larger lists.
This change optimizes search functionality by preventing potential slowdowns previously experienced with extensive lists

## Miscellaneous Updates

* Upgraded the UI library to the latest version, ensuring compatibility and incorporating potential improvements in functionality and design
* Project updated to .Net 8 and C# 12

## New Contributors

* @SergeyNefyodov made their first contribution in https://github.com/jeremytammik/RevitLookup/pull/187

Full changelog: https://github.com/jeremytammik/RevitLookup/compare/2024.0.8...2024.0.9

# 2023-06-22 **2024.0.8**

## Features
Expand Down
3 changes: 2 additions & 1 deletion Contributing.md
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,8 @@ public sealed class ElementDescriptor : Descriptor, IDescriptorConnector
{
if (_element is ElementType) return;

contextMenu.AddMenuItem("Show element")
contextMenu.AddMenuItem()
.SetHeader("Show element")
.SetCommand(_element, element =>
{
Application.ActionEventHandler.Raise(_ =>
Expand Down
2 changes: 1 addition & 1 deletion Installer/Installer.Tools.cs
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ public static Versions ComputeVersions(string[] args)
var assemblies = Directory.GetFiles(directory, @"RevitLookup.dll", SearchOption.AllDirectories);
if (assemblies.Length == 0) continue;

var version = new Version(FileVersionInfo.GetVersionInfo(assemblies[0]).ProductVersion);
var version = new Version(FileVersionInfo.GetVersionInfo(assemblies[0]).FileVersion);
return new Versions
{
AssemblyVersion = version,
Expand Down
19 changes: 5 additions & 14 deletions Readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,20 +31,11 @@ To ensure a proper code review, all code contributions must go through a pull re

We truly love pull requests! If you wish to help, you can learn more about how to contribute to this project in the [contribution guide](Contributing.md).

Maintained by [Nice3point](https://github.com/Nice3point), with invaluable [contributions](https://github.com/jeremytammik/RevitLookup/graphs/contributors)
from the entire Revit add-in developer community.

Thank you, guys!

- 2008-2022 &ndash; maintained by Jeremy Tammik,
[The Building Coder](http://thebuildingcoder.typepad.com),
[Autodesk Platform Services](https://aps.autodesk.com/),
[ADN](http://www.autodesk.com/adn)
[Open](http://www.autodesk.com/adnopen).
- 2005-05-11 &ndash; originally implemented
by [Jim Awe](https://www.linkedin.com/in/james-awe-4630a94/)
of [Autodesk Inc.](https://www.autodesk.com) as RvtMgdDbg.

| Date | Maintainer |
|:-----------:|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| Since 2022 | [Nice3point](https://github.com/Nice3point), with invaluable [contributions](https://github.com/jeremytammik/RevitLookup/graphs/contributors) from the entire Revit add-in developer community |
| 2008 - 2022 | Jeremy Tammik, [The Building Coder](http://thebuildingcoder.typepad.com), [Autodesk Platform Services](https://aps.autodesk.com/), [ADN](http://www.autodesk.com/adn) [Open](http://www.autodesk.com/adnopen) |
| 11 May 2005 | Originally implemented by [Jim Awe](https://www.linkedin.com/in/james-awe-4630a94/) of [Autodesk Inc.](https://www.autodesk.com) as RvtMgdDbg |

## License

Expand Down
105 changes: 23 additions & 82 deletions RevitLookup.UI.Demo/App.xaml.cs
Original file line number Diff line number Diff line change
@@ -1,41 +1,42 @@
// This Source Code Form is subject to the terms of the MIT License.
// If a copy of the MIT was not distributed with this file, You can obtain one at https://opensource.org/licenses/MIT.
// Copyright (C) Leszek Pomianowski and WPF UI Contributors.
// All Rights Reserved.
// Copyright 2003-2023 by Autodesk, Inc.
//
// Permission to use, copy, modify, and distribute this software in
// object code form for any purpose and without fee is hereby granted,
// provided that the above copyright notice appears in all copies and
// that both that copyright notice and the limited warranty and
// restricted rights notice below appear in all supporting
// documentation.
//
// AUTODESK PROVIDES THIS PROGRAM "AS IS" AND WITH ALL FAULTS.
// AUTODESK SPECIFICALLY DISCLAIMS ANY IMPLIED WARRANTY OF
// MERCHANTABILITY OR FITNESS FOR A PARTICULAR USE. AUTODESK, INC.
// DOES NOT WARRANT THAT THE OPERATION OF THE PROGRAM WILL BE
// UNINTERRUPTED OR ERROR FREE.
//
// Use, duplication, or disclosure by the U.S. Government is subject to
// restrictions set forth in FAR 52.227-19 (Commercial Computer
// Software - Restricted Rights) and DFAR 252.227-7013(c)(1)(ii)
// (Rights in Technical Data and Computer Software), as applicable.

using System.Diagnostics;
using System.IO;
using System.Reflection;
using System.Runtime.Versioning;
using System.Windows;
using Microsoft.Extensions.Configuration;
using Microsoft.Extensions.DependencyInjection;
using Microsoft.Extensions.Hosting;
using RevitLookup.Services;
using RevitLookup.Services.Contracts;
using RevitLookup.UI.Demo.Moq;
using RevitLookup.Utils;
using RevitLookup.ViewModels.Pages;
using RevitLookup.Views;
using RevitLookup.Views.Pages;
using Wpf.Ui.Contracts;
using Wpf.Ui.Services;

namespace RevitLookup.UI.Demo;

public sealed partial class App
{
private string _revitPath;

private async void OnStartup(object sender, StartupEventArgs e)
private void OnStartup(object sender, StartupEventArgs e)
{
AppDomain.CurrentDomain.AssemblyResolve += CurrentDomainOnAssemblyResolve;
var host = CreateHost();
Host.StartHost(host);
var host = HostProvider.CreateHost();

var window = Host.GetService<IWindow>();
window.Show();
window.Scope.GetService<INavigationService>().Navigate(typeof(DashboardView));
Host.StartHost(host);
Host.GetService<ILookupService>().Show<DashboardView>();
}

private void OnExit(object sender, ExitEventArgs e)
Expand All @@ -46,66 +47,6 @@ private void OnExit(object sender, ExitEventArgs e)
Host.StopHost();
}

private static IHost CreateHost()
{
var host = Microsoft.Extensions.Hosting.Host
.CreateDefaultBuilder()
.ConfigureAppConfiguration(builder =>
{
var assembly = Assembly.GetExecutingAssembly();
var assemblyLocation = assembly.Location;
var addinVersion = FileVersionInfo.GetVersionInfo(assemblyLocation).ProductVersion;
#if RELEASE
var version = addinVersion.Split('.')[0];
if (version == "1") version = "Develop";
var programDataPath = Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData);
var userDataLocation = Path.Combine(programDataPath, @"Autodesk\Revit\Addins\", version, "RevitLookup");
#else
var userDataLocation = Path.GetDirectoryName(assemblyLocation)!;
#endif
var appDataPath = Environment.GetFolderPath(Environment.SpecialFolder.CommonApplicationData);
var writeAccess = AccessUtils.CheckWriteAccess(assemblyLocation) && !assemblyLocation.StartsWith(appDataPath);

var targetFrameworkAttributes = assembly.GetCustomAttributes(typeof(TargetFrameworkAttribute), true);
var targetFrameworkAttribute = (TargetFrameworkAttribute) targetFrameworkAttributes.First();
var targetFramework = targetFrameworkAttribute.FrameworkDisplayName;

builder.AddInMemoryCollection(new KeyValuePair<string, string>[]
{
new("Assembly", assemblyLocation),
new("Framework", targetFramework),
new("AddinVersion", addinVersion),
new("ConfigFolder", Path.Combine(userDataLocation, "Config")),
new("DownloadFolder", Path.Combine(userDataLocation, "Downloads")),
new("FolderAccess", writeAccess ? "Write" : "Read")
});
})
.ConfigureServices((_, services) =>
{
services.AddSingleton<ISettingsService, SettingsService>();
services.AddSingleton<ISoftwareUpdateService, SoftwareUpdateService>();

services.AddScoped<IWindowController, WindowController>();
services.AddScoped<INavigationService, NavigationService>();
services.AddScoped<ISnackbarService, SnackbarService>();
services.AddScoped<IContentDialogService, ContentDialogService>();

services.AddScoped<AboutView>();
services.AddScoped<AboutViewModel>();
services.AddScoped<DashboardView>();
services.AddScoped<DashboardViewModel>();
services.AddScoped<SettingsView>();
services.AddScoped<SettingsViewModel>();
services.AddScoped<EventsView>();
services.AddScoped<EventsViewModel>();
services.AddScoped<SnoopView>();
services.AddScoped<ISnoopService, MoqSnoopViewModel>();

services.AddTransient<IWindow, RevitLookupView>();
}).Build();
return host;
}

private Assembly CurrentDomainOnAssemblyResolve(object sender, ResolveEventArgs args)
{
var assemblyName = new AssemblyName(args.Name);
Expand Down
Loading
Loading