Skip to content

Commit 1286bf5

Browse files
authored
Merge pull request #1233 from DNNCommunity/dev
Preparing the 8.2 GA release
2 parents 236abd5 + ae1dcec commit 1286bf5

File tree

426 files changed

+47440
-33969
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

426 files changed

+47440
-33969
lines changed

.editorconfig

+201
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,201 @@
1+
2+
# EditorConfig is awesome:http://EditorConfig.org
3+
4+
# top-most EditorConfig file
5+
root = true
6+
7+
# Standardize on CR/LF (Windows) line endings
8+
# Don't use tabs for indentation.
9+
[*]
10+
end_of_line = crlf
11+
indent_style = space
12+
# (Please don't specify an indent_size here; that has too many unintended consequences.)
13+
14+
[*.yml]
15+
indent_style = space
16+
indent_size = 2
17+
18+
# Code files
19+
[*.{cs,csx,vb,vbx}]
20+
indent_size = 4
21+
insert_final_newline = true
22+
charset = utf-8-bom
23+
24+
# Xml project files
25+
[*.{csproj,vbproj,vcxproj,vcxproj.filters,proj,projitems,shproj}]
26+
indent_size = 4
27+
28+
# Xml config files
29+
[*.{props,targets,ruleset,config,nuspec,resx,vsixmanifest,vsct}]
30+
indent_size = 2
31+
32+
# JSON files
33+
[*.json]
34+
indent_size = 2
35+
36+
[*.{sh}]
37+
end_of_line = lf
38+
indent_size = 2
39+
40+
# Dotnet code style settings:
41+
[*.{cs,vb}]
42+
# Sort using and Import directives with System.* appearing first
43+
dotnet_sort_system_directives_first = true
44+
45+
# Prefer "var" everywhere
46+
dotnet_style_qualification_for_field = true:suggestion
47+
dotnet_style_qualification_for_property = true:suggestion
48+
dotnet_style_qualification_for_method = true:suggestion
49+
dotnet_style_qualification_for_event = true:suggestion
50+
51+
# Use language keywords instead of framework type names for type references
52+
dotnet_style_predefined_type_for_locals_parameters_members = true:suggestion
53+
dotnet_style_predefined_type_for_member_access = true:suggestion
54+
55+
# Suggest more modern language features when available
56+
dotnet_style_object_initializer = true:suggestion
57+
dotnet_style_collection_initializer = true:suggestion
58+
dotnet_style_coalesce_expression = true:suggestion
59+
dotnet_style_null_propagation = true:suggestion
60+
dotnet_style_explicit_tuple_names = true:suggestion
61+
62+
# Non-private static fields are PascalCase
63+
dotnet_naming_rule.non_private_static_fields_should_be_pascal_case.severity = suggestion
64+
dotnet_naming_rule.non_private_static_fields_should_be_pascal_case.symbols = non_private_static_fields
65+
dotnet_naming_rule.non_private_static_fields_should_be_pascal_case.style = non_private_static_field_style
66+
67+
dotnet_naming_symbols.non_private_static_fields.applicable_kinds = field
68+
dotnet_naming_symbols.non_private_static_fields.applicable_accessibilities = public, protected, internal, protected internal, private protected
69+
dotnet_naming_symbols.non_private_static_fields.required_modifiers = static
70+
71+
dotnet_naming_style.non_private_static_field_style.capitalization = pascal_case
72+
73+
# Constants are PascalCase
74+
dotnet_naming_rule.constants_should_be_pascal_case.severity = suggestion
75+
dotnet_naming_rule.constants_should_be_pascal_case.symbols = constants
76+
dotnet_naming_rule.constants_should_be_pascal_case.style = non_private_static_field_style
77+
78+
dotnet_naming_symbols.constants.applicable_kinds = field, local
79+
dotnet_naming_symbols.constants.required_modifiers = const
80+
81+
dotnet_naming_style.constant_style.capitalization = pascal_case
82+
83+
# Static fields are camelCase and start with no prefix
84+
dotnet_naming_rule.static_fields_should_be_camel_case.severity = suggestion
85+
dotnet_naming_rule.static_fields_should_be_camel_case.symbols = static_fields
86+
dotnet_naming_rule.static_fields_should_be_camel_case.style = camel_case_style
87+
88+
dotnet_naming_symbols.static_fields.applicable_kinds = field
89+
dotnet_naming_symbols.static_fields.required_modifiers = static
90+
91+
dotnet_naming_style.static_field_style.capitalization = camel_case
92+
93+
# Instance fields are camelCase and start with no prefix
94+
dotnet_naming_rule.instance_fields_should_be_camel_case.severity = suggestion
95+
dotnet_naming_rule.instance_fields_should_be_camel_case.symbols = instance_fields
96+
dotnet_naming_rule.instance_fields_should_be_camel_case.style = camel_case_style
97+
98+
dotnet_naming_symbols.instance_fields.applicable_kinds = field
99+
100+
dotnet_naming_style.instance_field_style.capitalization = camel_case
101+
102+
# Locals and parameters are camelCase
103+
dotnet_naming_rule.locals_should_be_camel_case.severity = suggestion
104+
dotnet_naming_rule.locals_should_be_camel_case.symbols = locals_and_parameters
105+
dotnet_naming_rule.locals_should_be_camel_case.style = camel_case_style
106+
107+
dotnet_naming_symbols.locals_and_parameters.applicable_kinds = parameter, local
108+
109+
dotnet_naming_style.camel_case_style.capitalization = camel_case
110+
111+
# Local functions are PascalCase
112+
dotnet_naming_rule.local_functions_should_be_pascal_case.severity = suggestion
113+
dotnet_naming_rule.local_functions_should_be_pascal_case.symbols = local_functions
114+
dotnet_naming_rule.local_functions_should_be_pascal_case.style = non_private_static_field_style
115+
116+
dotnet_naming_symbols.local_functions.applicable_kinds = local_function
117+
118+
dotnet_naming_style.local_function_style.capitalization = pascal_case
119+
120+
# By default, name items with PascalCase
121+
dotnet_naming_rule.members_should_be_pascal_case.severity = suggestion
122+
dotnet_naming_rule.members_should_be_pascal_case.symbols = all_members
123+
dotnet_naming_rule.members_should_be_pascal_case.style = non_private_static_field_style
124+
125+
dotnet_naming_symbols.all_members.applicable_kinds = *
126+
127+
dotnet_naming_style.pascal_case_style.capitalization = pascal_case
128+
dotnet_style_operator_placement_when_wrapping = beginning_of_line
129+
tab_width = 4
130+
131+
# CSharp code style settings:
132+
[*.cs]
133+
# Indentation preferences
134+
csharp_indent_block_contents = true
135+
csharp_indent_braces = false
136+
csharp_indent_case_contents = true
137+
csharp_indent_case_contents_when_block = true
138+
csharp_indent_switch_labels = true
139+
csharp_indent_labels = flush_left
140+
141+
# Prefer "var" everywhere
142+
csharp_style_var_for_built_in_types = true:suggestion
143+
csharp_style_var_when_type_is_apparent = true:suggestion
144+
csharp_style_var_elsewhere = true:suggestion
145+
146+
# Prefer method-like constructs to have a block body
147+
csharp_style_expression_bodied_methods = false:none
148+
csharp_style_expression_bodied_constructors = false:none
149+
csharp_style_expression_bodied_operators = false:none
150+
151+
# Prefer property-like constructs to have an expression-body
152+
csharp_style_expression_bodied_properties = true:none
153+
csharp_style_expression_bodied_indexers = true:none
154+
csharp_style_expression_bodied_accessors = true:none
155+
156+
# Suggest more modern language features when available
157+
csharp_style_pattern_matching_over_is_with_cast_check = true:suggestion
158+
csharp_style_pattern_matching_over_as_with_null_check = true:suggestion
159+
csharp_style_inlined_variable_declaration = true:suggestion
160+
csharp_style_throw_expression = true:suggestion
161+
csharp_style_conditional_delegate_call = true:suggestion
162+
163+
# Newline settings
164+
csharp_new_line_before_open_brace = all
165+
csharp_new_line_before_else = true
166+
csharp_new_line_before_catch = true
167+
csharp_new_line_before_finally = true
168+
csharp_new_line_before_members_in_object_initializers = true
169+
csharp_new_line_before_members_in_anonymous_types = true
170+
csharp_new_line_between_query_expression_clauses = true
171+
172+
# Spacing
173+
csharp_space_after_cast = false
174+
csharp_space_after_colon_in_inheritance_clause = true
175+
csharp_space_after_keywords_in_control_flow_statements = true
176+
csharp_space_around_binary_operators = before_and_after
177+
csharp_space_before_colon_in_inheritance_clause = true
178+
csharp_space_between_method_call_empty_parameter_list_parentheses = false
179+
csharp_space_between_method_call_name_and_opening_parenthesis = false
180+
csharp_space_between_method_call_parameter_list_parentheses = false
181+
csharp_space_between_method_declaration_empty_parameter_list_parentheses = false
182+
csharp_space_between_method_declaration_parameter_list_parentheses = false
183+
csharp_space_between_parentheses = false
184+
185+
# Blocks are allowed
186+
csharp_prefer_braces = true:silent
187+
csharp_preserve_single_line_blocks = true
188+
csharp_preserve_single_line_statements = true
189+
190+
# ReSharper properties
191+
resharper_instance_members_qualify_members = field, property, event, method
192+
resharper_csharp_wrap_arguments_style = chop_if_long
193+
resharper_csharp_wrap_parameters_style = chop_if_long
194+
csharp_using_directive_placement = outside_namespace:silent
195+
csharp_prefer_simple_using_statement = true:suggestion
196+
csharp_style_namespace_declarations = block_scoped:silent
197+
csharp_style_prefer_method_group_conversion = true:silent
198+
csharp_style_prefer_top_level_statements = true:silent
199+
csharp_style_prefer_primary_constructors = true:suggestion
200+
csharp_style_expression_bodied_lambdas = true:silent
201+
csharp_style_expression_bodied_local_functions = false:silent

.gitignore

-1
Original file line numberDiff line numberDiff line change
@@ -113,7 +113,6 @@ AppPackages/
113113
# Others
114114
*.Cache
115115
ClientBin/
116-
[Ss]tyle[Cc]op.*
117116
~$*
118117
*~
119118
*.dbmdl

Dnn.CommunityForums/08.02.00.txt

+25
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
DesktopModules/ActiveForums/config/templates/BlogList.ascx
2+
DesktopModules/ActiveForums/config/templates/BlogsView.ascx
3+
DesktopModules/ActiveForums/config/templates/BlogView.ascx
4+
DesktopModules/ActiveForums/config/templates/ForumTracking.ascx
5+
DesktopModules/ActiveForums/themes/community-default/templates/AdminWatchEmail.ascx
6+
DesktopModules/ActiveForums/themes/community-default/templates/ModAlert.ascx
7+
DesktopModules/ActiveForums/themes/community-default/templates/PostApproved.ascx
8+
DesktopModules/ActiveForums/themes/community-default/templates/PostDeleted.ascx
9+
DesktopModules/ActiveForums/themes/community-default/templates/PostMoved.ascx
10+
DesktopModules/ActiveForums/themes/community-default/templates/PostPending.ascx
11+
DesktopModules/ActiveForums/themes/community-default/templates/PostRejected.ascx
12+
DesktopModules/ActiveForums/themes/community-default/templates/ReplyEditor.ascx
13+
DesktopModules/ActiveForums/themes/community-default/templates/SubscribedEmail.ascx
14+
DesktopModules/ActiveForums/themes/community-default/templates/Toolbar.ascx
15+
DesktopModules/ActiveForums/themes/community-bootstrap/templates/AdminWatchEmail.ascx
16+
DesktopModules/ActiveForums/themes/community-bootstrap/templates/ModAlert.ascx
17+
DesktopModules/ActiveForums/themes/community-bootstrap/templates/PostApproved.ascx
18+
DesktopModules/ActiveForums/themes/community-bootstrap/templates/PostDeleted.ascx
19+
DesktopModules/ActiveForums/themes/community-bootstrap/templates/PostMoved.ascx
20+
DesktopModules/ActiveForums/themes/community-bootstrap/templates/PostPending.ascx
21+
DesktopModules/ActiveForums/themes/community-bootstrap/templates/PostRejected.ascx
22+
DesktopModules/ActiveForums/themes/community-bootstrap/templates/SubscribedEmail.ascx
23+
DesktopModules/ActiveForums/themes/community-bootstrap/templates/Toolbar.ascx
24+
DesktopModules/ActiveForums/app.config
25+
DesktopModules/ActiveForums/packages.config

Dnn.CommunityForums/ActiveForumViewer.ascx.cs

+42-37
Original file line numberDiff line numberDiff line change
@@ -1,28 +1,29 @@
1-
//
2-
// Community Forums
3-
// Copyright (c) 2013-2024
4-
// by DNN Community
1+
// Copyright (c) by DNN Community
52
//
6-
// Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated
7-
// documentation files (the "Software"), to deal in the Software without restriction, including without limitation
8-
// the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and
3+
// DNN Community licenses this file to you under the MIT license.
4+
//
5+
// See the LICENSE file in the project root for more information.
6+
//
7+
// Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated
8+
// documentation files (the "Software"), to deal in the Software without restriction, including without limitation
9+
// the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and
910
// to permit persons to whom the Software is furnished to do so, subject to the following conditions:
1011
//
11-
// The above copyright notice and this permission notice shall be included in all copies or substantial portions
12+
// The above copyright notice and this permission notice shall be included in all copies or substantial portions
1213
// of the Software.
1314
//
14-
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
15-
// TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
16-
// THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF
17-
// CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
15+
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
16+
// TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
17+
// THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF
18+
// CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
1819
// DEALINGS IN THE SOFTWARE.
1920

20-
using System;
21-
using System.Linq;
22-
using System.Web.UI.WebControls;
23-
2421
namespace DotNetNuke.Modules.ActiveForums
2522
{
23+
using System;
24+
using System.Linq;
25+
using System.Web.UI.WebControls;
26+
2627
public partial class ActiveForumViewer : ForumBase
2728
{
2829
#region Event Handlers
@@ -32,47 +33,51 @@ protected override void OnLoad(EventArgs e)
3233

3334
try
3435
{
35-
if (Settings[ForumViewerSettingsKeys.AFForumModuleId] != null)
36+
if (this.Settings[ForumViewerSettingsKeys.AFForumModuleId] != null)
3637
{
37-
string viewType = Convert.ToString(Settings[ForumViewerSettingsKeys.AFViewType]);
38-
int tmpModuleId = Convert.ToInt32(Settings[ForumViewerSettingsKeys.AFForumModuleId]);
39-
int tmpForumId = Convert.ToInt32(Settings[ForumViewerSettingsKeys.AFForumGroupId]);
38+
string viewType = Convert.ToString(this.Settings[ForumViewerSettingsKeys.AFViewType]);
39+
int tmpModuleId = Convert.ToInt32(this.Settings[ForumViewerSettingsKeys.AFForumModuleId]);
40+
int tmpForumId = Convert.ToInt32(this.Settings[ForumViewerSettingsKeys.AFForumGroupId]);
4041
if (viewType.ToLowerInvariant() == "topics")
4142
{
4243
viewType = Views.Topics;
43-
ctlForumLoader.ForumId = tmpForumId;
44+
this.ctlForumLoader.ForumId = tmpForumId;
4445
}
4546
else
4647
{
4748
viewType = Views.ForumView;
48-
ctlForumLoader.ForumGroupId = tmpForumId;
49+
this.ctlForumLoader.ForumGroupId = tmpForumId;
4950
}
50-
ctlForumLoader.DefaultView = viewType;
51-
ctlForumLoader.ForumModuleId = tmpModuleId;
52-
ctlForumLoader.ForumTabId = ForumTabId;
51+
52+
this.ctlForumLoader.DefaultView = viewType;
53+
this.ctlForumLoader.ForumModuleId = tmpModuleId;
54+
this.ctlForumLoader.ForumTabId = this.ForumTabId;
5355
int tmpForumTabId = DotNetNuke.Entities.Modules.ModuleController.Instance.GetTabModulesByModule(tmpModuleId).FirstOrDefault().TabID;
54-
if (tmpForumTabId <= 0) { tmpForumTabId = TabId; }
55-
ctlForumLoader.ForumTabId = tmpForumTabId;
56-
ctlForumLoader.ModuleConfiguration = this.ModuleConfiguration;
57-
if (!(Convert.ToString(Settings[ForumViewerSettingsKeys.AFTopicsTemplate]) == null))
56+
if (tmpForumTabId <= 0) { tmpForumTabId = this.TabId; }
57+
this.ctlForumLoader.ForumTabId = tmpForumTabId;
58+
this.ctlForumLoader.ModuleConfiguration = this.ModuleConfiguration;
59+
if (!(Convert.ToString(this.Settings[ForumViewerSettingsKeys.AFTopicsTemplate]) == null))
5860
{
59-
ctlForumLoader.DefaultTopicsViewTemplateId = Convert.ToInt32(Settings[ForumViewerSettingsKeys.AFTopicsTemplate]);
61+
this.ctlForumLoader.DefaultTopicsViewTemplateId = Convert.ToInt32(this.Settings[ForumViewerSettingsKeys.AFTopicsTemplate]);
6062
}
61-
if (!(Convert.ToString(Settings[ForumViewerSettingsKeys.AFForumViewTemplate]) == null))
63+
64+
if (!(Convert.ToString(this.Settings[ForumViewerSettingsKeys.AFForumViewTemplate]) == null))
6265
{
63-
ctlForumLoader.DefaultForumViewTemplateId = Convert.ToInt32(Settings[ForumViewerSettingsKeys.AFForumViewTemplate]);
66+
this.ctlForumLoader.DefaultForumViewTemplateId = Convert.ToInt32(this.Settings[ForumViewerSettingsKeys.AFForumViewTemplate]);
6467
}
65-
if (!(Convert.ToString(Settings[ForumViewerSettingsKeys.AFTopicTemplate]) == null))
68+
69+
if (!(Convert.ToString(this.Settings[ForumViewerSettingsKeys.AFTopicTemplate]) == null))
6670
{
67-
ctlForumLoader.DefaultTopicViewTemplateId = Convert.ToInt32(Settings[ForumViewerSettingsKeys.AFTopicTemplate]);
71+
this.ctlForumLoader.DefaultTopicViewTemplateId = Convert.ToInt32(this.Settings[ForumViewerSettingsKeys.AFTopicTemplate]);
6872
}
73+
6974
System.Web.UI.HtmlControls.HtmlGenericControl oLink = new System.Web.UI.HtmlControls.HtmlGenericControl("link");
7075
oLink.Attributes["rel"] = "stylesheet";
71-
oLink.Attributes["type"] = "text/css";
72-
oLink.Attributes["href"] = Page.ResolveUrl(Globals.ModulePath + "module.css");
76+
oLink.Attributes["type"] = "text/css";
77+
oLink.Attributes["href"] = this.Page.ResolveUrl(Globals.ModulePath + "module.css");
7378
System.Web.UI.Control oCSS = this.Page.FindControl("CSS");
7479
if (oCSS != null)
75-
{
80+
{
7681
int iControlIndex = 0;
7782
iControlIndex = oCSS.Controls.Count;
7883
oCSS.Controls.AddAt(0, oLink);

0 commit comments

Comments
 (0)