aboutsummaryrefslogtreecommitdiffstats
path: root/ethereal/assets/qml/webapp.qml
diff options
context:
space:
mode:
authorobscuren <geffobscura@gmail.com>2014-08-13 16:52:30 +0800
committerobscuren <geffobscura@gmail.com>2014-08-13 16:52:30 +0800
commitd518423b9c493bf5b42e6575db9a32106812e6bc (patch)
tree17bb79aee6e218fd63f2a3b03a28f2f0d7faf1ca /ethereal/assets/qml/webapp.qml
parent1fa792eae7584f61624121e46dbad82484109c64 (diff)
downloaddexon-d518423b9c493bf5b42e6575db9a32106812e6bc.tar
dexon-d518423b9c493bf5b42e6575db9a32106812e6bc.tar.gz
dexon-d518423b9c493bf5b42e6575db9a32106812e6bc.tar.bz2
dexon-d518423b9c493bf5b42e6575db9a32106812e6bc.tar.lz
dexon-d518423b9c493bf5b42e6575db9a32106812e6bc.tar.xz
dexon-d518423b9c493bf5b42e6575db9a32106812e6bc.tar.zst
dexon-d518423b9c493bf5b42e6575db9a32106812e6bc.zip
Updated DNS Lookup
Diffstat (limited to 'ethereal/assets/qml/webapp.qml')
-rw-r--r--ethereal/assets/qml/webapp.qml8
1 files changed, 6 insertions, 2 deletions
diff --git a/ethereal/assets/qml/webapp.qml b/ethereal/assets/qml/webapp.qml
index 15177e3fd..a848adf45 100644
--- a/ethereal/assets/qml/webapp.qml
+++ b/ethereal/assets/qml/webapp.qml
@@ -31,9 +31,13 @@ ApplicationWindow {
//text: webview.url
Keys.onReturnPressed: {
+ var uri = this.text;
+ if(!/.*\:\/\/.*/.test(uri)) {
+ uri = "http://" + uri;
+ }
+
var reg = /(^https?\:\/\/(?:www\.)?)([a-zA-Z0-9_\-]*\.eth)(.*)/
- var uri = this.text;
if(reg.test(uri)) {
this.text.replace(reg, function(match, pre, domain, path) {
uri = pre;
@@ -45,7 +49,7 @@ ApplicationWindow {
}
if(ip.length != 0) {
- uri += ip.join(".");
+ uri += lookup;
} else {
uri += domain;
}