Skip to content

Commit

Permalink
Nuked several Technology Test project files: we know we won't be usin…
Browse files Browse the repository at this point in the history
…g WPF for future development (non-portable) and moving to a more web-oriented approach (using Chromely when that's doable, otherwise going with our own mix of C# "business logic layer" and HTML+CSS+JS Browser-based UI frontend, `electron`-like.

Also added a few other 'Technology Test' projects, just to see what Visual Studio would do (TypeScript stuff, etc.)
  • Loading branch information
GerHobbelt committed Mar 23, 2021
1 parent 0a12964 commit 2859d5b
Show file tree
Hide file tree
Showing 243 changed files with 21,083 additions and 2,739 deletions.
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,8 @@ Qiqqa.Build/Packaging/ClickOnceUninstaller/ClickOnceUninstaller/obj/*

# nodeJS stuff (npm)
/node_modules
/Technology Tests/TypeScript Console App/node_modules
/Technology Tests/TypeScript VueJS App/node_modules

# ignore directories where the installers are saved during Release+SETUP builds
/Qiqqa.Build/Packages/v* - 20*/
Expand Down
594 changes: 6 additions & 588 deletions Qiqqa.sln

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
<Application
x:Class="WpfBrowserApp1.App"
x:Class="CEFSharp_Functionality_and_Viability_Demo.App"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:local="clr-namespace:WpfBrowserApp1"
xmlns:local="clr-namespace:CEFSharp_Functionality_and_Viability_Demo"
StartupUri="Page1.xaml">
<Application.Resources />
</Application>
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
using System.Windows;
using System.Windows.Navigation;

namespace WpfBrowserApp1
namespace CEFSharp_Functionality_and_Viability_Demo
{
/// <summary>
/// Interaction logic for App.xaml
Expand Down
Binary file not shown.
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,10 @@
<PropertyGroup>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
<ProjectGuid>{C38C96A8-C198-4155-BAF4-F209BA6DA947}</ProjectGuid>
<ProjectGuid>{31A26F7A-AAF4-4AF4-B237-5A84167D32AF}</ProjectGuid>
<OutputType>WinExe</OutputType>
<RootNamespace>WpfBrowserApp1</RootNamespace>
<AssemblyName>WpfBrowserApp1</AssemblyName>
<RootNamespace>CEFGlue_Functionality_and_Viability_Demo</RootNamespace>
<AssemblyName>CEFGluee Functionality and Viability Demo</AssemblyName>
<TargetFrameworkVersion>v4.8</TargetFrameworkVersion>
<FileAlignment>512</FileAlignment>
<ProjectTypeGuids>{60dc8134-eba5-43b8-bcc9-bb4bc16c2548};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids>
Expand Down Expand Up @@ -91,21 +91,23 @@
<Generator>ResXFileCodeGenerator</Generator>
<LastGenOutput>Resources.Designer.cs</LastGenOutput>
</EmbeddedResource>
<None Include="CEFGlue Functionality and Viability Demo_TemporaryKey.pfx" />
<None Include="Properties\Settings.settings">
<Generator>SettingsSingleFileGenerator</Generator>
<LastGenOutput>Settings.Designer.cs</LastGenOutput>
</None>
<None Include="Properties\app.manifest" />
<None Include="WpfBrowserApp1_TemporaryKey.pfx" />
<None Include="README.md" />
</ItemGroup>
<Import Project="..\Technology Library\Technology Library.projitems" Label="Shared" />
<PropertyGroup>
<StartArguments />
</PropertyGroup>
<PropertyGroup>
<ManifestKeyFile>WpfBrowserApp1_TemporaryKey.pfx</ManifestKeyFile>
<ManifestKeyFile>CEFGlue Functionality and Viability Demo_TemporaryKey.pfx</ManifestKeyFile>
</PropertyGroup>
<PropertyGroup>
<ManifestCertificateThumbprint>FC540ADF799BDA7E7DB295F355A4EA038D96072F</ManifestCertificateThumbprint>
<ManifestCertificateThumbprint>473D4A1CEC80F8A18AA803EEA11132BF0407DA3B</ManifestCertificateThumbprint>
</PropertyGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
</Project>
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
<Page x:Class="WpfBrowserApp1.Page1"
<Page x:Class="CEFSharp_Functionality_and_Viability_Demo.Page1"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:local="clr-namespace:WpfBrowserApp1"
xmlns:local="clr-namespace:CEFSharp_Functionality_and_Viability_Demo"
mc:Ignorable="d"
d:DesignHeight="450" d:DesignWidth="800"
Title="Page1">
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
using System.Windows.Navigation;
using System.Windows.Shapes;

namespace WpfBrowserApp1
namespace CEFSharp_Functionality_and_Viability_Demo
{
/// <summary>
/// Interaction logic for Page1.xaml
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,11 @@
// General Information about an assembly is controlled through the following
// set of attributes. Change these attribute values to modify the information
// associated with an assembly.
[assembly: AssemblyTitle("WpfBrowserApp1")]
[assembly: AssemblyTitle("CEFGlue Functionality and Viability Demo")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("Quantisle")]
[assembly: AssemblyProduct("WpfBrowserApp1")]
[assembly: AssemblyProduct("CEFGlue Functionality and Viability Demo")]
[assembly: AssemblyCopyright("Copyright © Quantisle 2010-2020. All rights reserved.")]
[assembly: AssemblyTrademark("")]
[assembly: AssemblyCulture("")]
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
# WPF-based CEFGlue embedded browser Usability & Viability Tester / Demo

## Purpose

To discover what needs to be done to make CEFGlue our new all-purpose embedded browser control.

Key features which must be supported:

- hook/observe any content that's coming in from a website. This includes:
+ clicked PDFs, whether they are going to be viewed in-browser or downloaded
+ content which is of any MIME type: plain text may be valid BibTeX or other metadata formats which we might want to grab & import.
+ any page HTML for we must be able to 'read the page' and find any links in there, possibly even a bit of content scraping as well.
+ when part of the page is cacched, e.g. when we re-visit a page, we SHOULD be able to hok and grab the cached content as well as there *might* be a retry attempt from the user to grab a PDF or metadata file (BibTeX as plaintext, etc.) -- I've done this type of action myself in the past quite a few times as there were intermittant network errors or whatever kind of issue that seemed to crap up the PDF grab on the first round, hence you go 'Back' and *retry*. The old XULrunner sometimes would not cooperate due to caching and thus no actual HTTP request to the server we could grab on the re-run. :-(
+ must support use of multiple views, using a single instance, or at least in a setting where you "log in" in a site in one view, and the other views get the login update via website cookies, just like would happen when you had multiple tabs open in a browser and hit *F5-refresh* on the other tabs after you've logged in in one tab only: all the tabs should 'see' this.
+ allow keyboard shortcuts, such as F5-refresh, to arrive at the embedded browser.
+ MAY have the ability to 'inject' (user/Qiqqa-defined) JavaScript in a page // or we might want to support Chrome extensions such as WitchCraft or User JavaScript And CSS.
+ have support for browser-displayed page interrogation (e.g. getting a dump of the displayed DOM)
+ or even better: have full Chrome Debugger support available and usable.



---

## Motto

This here is part of the technical storyboarding side of a UI & UX overhaul of Qiqqa.

Before we put it to Qiqqa, it will be tested here.
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

## Purpose

To disccover what needs to be done to make CEFSharp our new all-purpose embedded browser control.
To discover what needs to be done to make CEFSharp our new all-purpose embedded browser control.

Key features which must be supported:

Expand Down
181 changes: 181 additions & 0 deletions Technology Tests/Cpp Windows App/Cpp Windows App.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,181 @@
// Cpp Windows App.cpp : Defines the entry point for the application.
//

#include "pch.h"
#include "framework.h"
#include "Cpp Windows App.h"

#define MAX_LOADSTRING 100

// Global Variables:
HINSTANCE hInst; // current instance
WCHAR szTitle[MAX_LOADSTRING]; // The title bar text
WCHAR szWindowClass[MAX_LOADSTRING]; // the main window class name

// Forward declarations of functions included in this code module:
ATOM MyRegisterClass(HINSTANCE hInstance);
BOOL InitInstance(HINSTANCE, int);
LRESULT CALLBACK WndProc(HWND, UINT, WPARAM, LPARAM);
INT_PTR CALLBACK About(HWND, UINT, WPARAM, LPARAM);

int APIENTRY wWinMain(_In_ HINSTANCE hInstance,
_In_opt_ HINSTANCE hPrevInstance,
_In_ LPWSTR lpCmdLine,
_In_ int nCmdShow)
{
UNREFERENCED_PARAMETER(hPrevInstance);
UNREFERENCED_PARAMETER(lpCmdLine);

// TODO: Place code here.

// Initialize global strings
LoadStringW(hInstance, IDS_APP_TITLE, szTitle, MAX_LOADSTRING);
LoadStringW(hInstance, IDC_CPPWINDOWSAPP, szWindowClass, MAX_LOADSTRING);
MyRegisterClass(hInstance);

// Perform application initialization:
if (!InitInstance (hInstance, nCmdShow))
{
return FALSE;
}

HACCEL hAccelTable = LoadAccelerators(hInstance, MAKEINTRESOURCE(IDC_CPPWINDOWSAPP));

MSG msg;

// Main message loop:
while (GetMessage(&msg, nullptr, 0, 0))
{
if (!TranslateAccelerator(msg.hwnd, hAccelTable, &msg))
{
TranslateMessage(&msg);
DispatchMessage(&msg);
}
}

return (int) msg.wParam;
}



//
// FUNCTION: MyRegisterClass()
//
// PURPOSE: Registers the window class.
//
ATOM MyRegisterClass(HINSTANCE hInstance)
{
WNDCLASSEXW wcex;

wcex.cbSize = sizeof(WNDCLASSEX);

wcex.style = CS_HREDRAW | CS_VREDRAW;
wcex.lpfnWndProc = WndProc;
wcex.cbClsExtra = 0;
wcex.cbWndExtra = 0;
wcex.hInstance = hInstance;
wcex.hIcon = LoadIcon(hInstance, MAKEINTRESOURCE(IDI_CPPWINDOWSAPP));
wcex.hCursor = LoadCursor(nullptr, IDC_ARROW);
wcex.hbrBackground = (HBRUSH)(COLOR_WINDOW+1);
wcex.lpszMenuName = MAKEINTRESOURCEW(IDC_CPPWINDOWSAPP);
wcex.lpszClassName = szWindowClass;
wcex.hIconSm = LoadIcon(wcex.hInstance, MAKEINTRESOURCE(IDI_SMALL));

return RegisterClassExW(&wcex);
}

//
// FUNCTION: InitInstance(HINSTANCE, int)
//
// PURPOSE: Saves instance handle and creates main window
//
// COMMENTS:
//
// In this function, we save the instance handle in a global variable and
// create and display the main program window.
//
BOOL InitInstance(HINSTANCE hInstance, int nCmdShow)
{
hInst = hInstance; // Store instance handle in our global variable

HWND hWnd = CreateWindowW(szWindowClass, szTitle, WS_OVERLAPPEDWINDOW,
CW_USEDEFAULT, 0, CW_USEDEFAULT, 0, nullptr, nullptr, hInstance, nullptr);

if (!hWnd)
{
return FALSE;
}

ShowWindow(hWnd, nCmdShow);
UpdateWindow(hWnd);

return TRUE;
}

//
// FUNCTION: WndProc(HWND, UINT, WPARAM, LPARAM)
//
// PURPOSE: Processes messages for the main window.
//
// WM_COMMAND - process the application menu
// WM_PAINT - Paint the main window
// WM_DESTROY - post a quit message and return
//
//
LRESULT CALLBACK WndProc(HWND hWnd, UINT message, WPARAM wParam, LPARAM lParam)
{
switch (message)
{
case WM_COMMAND:
{
int wmId = LOWORD(wParam);
// Parse the menu selections:
switch (wmId)
{
case IDM_ABOUT:
DialogBox(hInst, MAKEINTRESOURCE(IDD_ABOUTBOX), hWnd, About);
break;
case IDM_EXIT:
DestroyWindow(hWnd);
break;
default:
return DefWindowProc(hWnd, message, wParam, lParam);
}
}
break;
case WM_PAINT:
{
PAINTSTRUCT ps;
HDC hdc = BeginPaint(hWnd, &ps);
// TODO: Add any drawing code that uses hdc here...
EndPaint(hWnd, &ps);
}
break;
case WM_DESTROY:
PostQuitMessage(0);
break;
default:
return DefWindowProc(hWnd, message, wParam, lParam);
}
return 0;
}

// Message handler for about box.
INT_PTR CALLBACK About(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam)
{
UNREFERENCED_PARAMETER(lParam);
switch (message)
{
case WM_INITDIALOG:
return (INT_PTR)TRUE;

case WM_COMMAND:
if (LOWORD(wParam) == IDOK || LOWORD(wParam) == IDCANCEL)
{
EndDialog(hDlg, LOWORD(wParam));
return (INT_PTR)TRUE;
}
break;
}
return (INT_PTR)FALSE;
}
3 changes: 3 additions & 0 deletions Technology Tests/Cpp Windows App/Cpp Windows App.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
#pragma once

#include "resource.h"
Binary file not shown.
Binary file not shown.
Loading

0 comments on commit 2859d5b

Please sign in to comment.